Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[fix] Fix error like:aused by: org.apache.http.ProtocolException: Transfer-encoding header already present #525

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

awol2005ex
Copy link

[fix] Fix error like:
Caused by: org.apache.http.ProtocolException: Transfer-encoding header already present
at org.apache.http.protocol.RequestContent.process(RequestContent.java:93) ~[xxx-cdh-flink1-20-0-sql-gitlab-runner-1.0.0.jar:?]
at org.apache.http.protocol.ImmutableHttpProcessor.process(ImmutableHttpProcessor.java:132) ~[xxx-cdh-flink1-20-0-sql-gitlab-runner-1.0.0.jar:?]
at org.apache.http.impl.execchain.ProtocolExec.execute(ProtocolExec.java:182) ~[xxx-cdh-flink1-20-0-sql-gitlab-runner-1.0.0.jar:?]
at org.apache.http.impl.execchain.RetryExec.execute(RetryExec.java:88) ~[xxx-cdh-flink1-20-0-sql-gitlab-runner-1.0.0.jar:?]
at org.apache.http.impl.execchain.RedirectExec.execute(RedirectExec.java:110) ~[xxx-cdh-flink1-20-0-sql-gitlab-runner-1.0.0.jar:?]
at org.apache.http.impl.client.InternalHttpClient.doExecute(InternalHttpClient.java:184) ~[xxx-cdh-flink1-20-0-sql-gitlab-runner-1.0.0.jar:?]
at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:82) ~[xxx-cdh-flink1-20-0-sql-gitlab-runner-1.0.0.jar:?]
at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:107) ~[xxx-cdh-flink1-20-0-sql-gitlab-runner-1.0.0.jar:?]
at org.apache.doris.flink.sink.writer.DorisStreamLoad.lambda$startLoad$0(DorisStreamLoad.java:347) ~[xxx-cdh-flink1-20-0-sql-gitlab-runner-1.0.0.jar:?]
at java.util.concurrent.FutureTask.run(FutureTask.java:266) ~[?:1.8.0_232]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) ~[?:1.8.0_232]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) ~[?:1.8.0_232]
... 1 more

Caused by: org.apache.http.ProtocolException: Transfer-encoding header already present
	at org.apache.http.protocol.RequestContent.process(RequestContent.java:93) ~[xxx-cdh-flink1-20-0-sql-gitlab-runner-1.0.0.jar:?]
	at org.apache.http.protocol.ImmutableHttpProcessor.process(ImmutableHttpProcessor.java:132) ~[xxx-cdh-flink1-20-0-sql-gitlab-runner-1.0.0.jar:?]
	at org.apache.http.impl.execchain.ProtocolExec.execute(ProtocolExec.java:182) ~[xxx-cdh-flink1-20-0-sql-gitlab-runner-1.0.0.jar:?]
	at org.apache.http.impl.execchain.RetryExec.execute(RetryExec.java:88) ~[xxx-cdh-flink1-20-0-sql-gitlab-runner-1.0.0.jar:?]
	at org.apache.http.impl.execchain.RedirectExec.execute(RedirectExec.java:110) ~[xxx-cdh-flink1-20-0-sql-gitlab-runner-1.0.0.jar:?]
	at org.apache.http.impl.client.InternalHttpClient.doExecute(InternalHttpClient.java:184) ~[xxx-cdh-flink1-20-0-sql-gitlab-runner-1.0.0.jar:?]
	at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:82) ~[xxx-cdh-flink1-20-0-sql-gitlab-runner-1.0.0.jar:?]
	at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:107) ~[xxx-cdh-flink1-20-0-sql-gitlab-runner-1.0.0.jar:?]
	at org.apache.doris.flink.sink.writer.DorisStreamLoad.lambda$startLoad$0(DorisStreamLoad.java:347) ~[xxx-cdh-flink1-20-0-sql-gitlab-runner-1.0.0.jar:?]
	at java.util.concurrent.FutureTask.run(FutureTask.java:266) ~[?:1.8.0_232]
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) ~[?:1.8.0_232]
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) ~[?:1.8.0_232]
	... 1 more
@JNSimba
Copy link
Member

JNSimba commented Dec 6, 2024

Thank you for your contribution. Under what circumstances does this occur?

@awol2005ex
Copy link
Author

Thank you for your contribution. Under what circumstances does this occur?

This occurs when Flink consumes from Kafka and writes into Doris

@JNSimba
Copy link
Member

JNSimba commented Dec 9, 2024

Thank you for your contribution. Under what circumstances does this occur?

This occurs when Flink consumes from Kafka and writes into Doris

Can you provide a way to reproduce the problem, as well as the complete log of TaskManager, and the versions of Doris and Flink Doris connector?

@awol2005ex
Copy link
Author

awol2005ex commented Dec 9, 2024

Thank you for your contribution. Under what circumstances does this occur?

This occurs when Flink consumes from Kafka and writes into Doris

Can you provide a way to reproduce the problem, as well as the complete log of TaskManager, and the versions of Doris and Flink Doris connector?

flink 1.20 doris 2.1.6 doris-flink-connector

<dependency> <groupId>org.apache.doris</groupId> <artifactId>flink-doris-connector-1.20</artifactId> <version>24.0.1</version> </dependency>

`
create table a1 (
id varchar,
........
) with (
'connector' = 'kafka',
'topic' = 'xxxxxxx',
'scan.startup.mode' = 'earliest-offset',
'properties.zookeeper.connect' = 'xxxxx:2181/kafka',
'properties.bootstrap.servers' = 'xxxxx:9092',
'properties.group.id' = 'flink-sql-kafka-hz-20241206',
'properties.security.protocol' = 'SASL_PLAINTEXT',
'properties.sasl.kerberos.service.name' = 'kafka',
'properties.sasl.mechanism' = 'GSSAPI',
'value.format' = 'json'
)

create table a2 (
id string,
....
) with (
'connector' = 'doris',
'fenodes' = 'xxxxxx:8030',
'table.identifier' = 'test.a2',
'username' = 'root',
'password' = 'xxxxx',
'sink.label-prefix' = 'xxxxxx',
'sink.properties.format' = 'json',
'sink.properties.read_json_by_line' = 'true'

)

insert into a2 select * from a1;
`

Caused by: org.apache.http.ProtocolException: Transfer-encoding header already present at org.apache.http.protocol.RequestContent.process(RequestContent.java:93) ~[xxx-cdh-flink1-20-0-sql-gitlab-runner-1.0.0.jar:?] at org.apache.http.protocol.ImmutableHttpProcessor.process(ImmutableHttpProcessor.java:132) ~[xxx-cdh-flink1-20-0-sql-gitlab-runner-1.0.0.jar:?] at org.apache.http.impl.execchain.ProtocolExec.execute(ProtocolExec.java:182) ~[xxx-cdh-flink1-20-0-sql-gitlab-runner-1.0.0.jar:?] at org.apache.http.impl.execchain.RetryExec.execute(RetryExec.java:88) ~[xxx-cdh-flink1-20-0-sql-gitlab-runner-1.0.0.jar:?] at org.apache.http.impl.execchain.RedirectExec.execute(RedirectExec.java:110) ~[xxx-cdh-flink1-20-0-sql-gitlab-runner-1.0.0.jar:?] at org.apache.http.impl.client.InternalHttpClient.doExecute(InternalHttpClient.java:184) ~[xxx-cdh-flink1-20-0-sql-gitlab-runner-1.0.0.jar:?] at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:82) ~[xxx-cdh-flink1-20-0-sql-gitlab-runner-1.0.0.jar:?] at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:107) ~[xxx-cdh-flink1-20-0-sql-gitlab-runner-1.0.0.jar:?] at org.apache.doris.flink.sink.writer.DorisStreamLoad.lambda$startLoad$0(DorisStreamLoad.java:347) ~[xxx-cdh-flink1-20-0-sql-gitlab-runner-1.0.0.jar:?] at java.util.concurrent.FutureTask.run(FutureTask.java:266) ~[?:1.8.0_232] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) ~[?:1.8.0_232] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) ~[?:1.8.0_232] ... 1 more

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants