简体   繁体   English

无法与码头化生产者一起生产到卡夫卡

[英]Can not produce with dockerized producer into Kafka

Did anyone encounter this error ? 有没有人遇到这个错误?

io.confluent.kafka.schemaregistry.client.rest.exceptions.RestClientException: Unexpected character ('<' (code 60)): expected a valid value (number, String, array, object, 'true', 'false' or 'null')\n at [Source: (sun.net.www.protocol.http.HttpURLConnection$HttpInputStream); line: 1, column: 2]; error code: 50005\n\tat io.confluent.kafka.schemaregistry.client.rest.RestService.sendHttpRequest(RestService.java:226)

I have this stack trace when I try to produce messages into kafka. 当我尝试将消息发送到kafka时,我有这个堆栈跟踪。

FYI, the kafka stack (kaka, schema-registry and zookeeper) and the producer are dockerized with a docker-compose file. 仅供参考,kafka堆栈(kaka,schema-registry和zookeeper)和生产者使用docker-compose文件进行码头化。

Any help is appreciated ! 任何帮助表示赞赏!

I'm using a proxy, I added my IP address to http.nonProxyHosts and it works. 我正在使用代理,我将我的IP地址添加到http.nonProxyHosts并且它可以工作。 The problem was the schema-registry returning HTML rather than JSON, that's why I had this annoying error. 问题是模式注册表返回HTML而不是JSON,这就是为什么我有这个恼人的错误。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM