Confluent架构注册表在启动时失败

时间:2017-10-17 11:12:08

标签: apache-kafka apache-zookeeper confluent-schema-registry

Exception in thread "main" java.lang.NoSuchMethodError: io.confluent.rest.Application.parseListeners(Ljava/util/List;ILjava/util/List;Ljava/lang/String;)Ljava/util/List;
at io.confluent.kafka.schemaregistry.storage.KafkaSchemaRegistry.getPortForIdentity(KafkaSchemaRegistry.java:204)
at io.confluent.kafka.schemaregistry.storage.KafkaSchemaRegistry.(KafkaSchemaRegistry.java:133)

等/架构的注册表/ schema-registry.properties

 listeners=http://0.0.0.0:8081 
 kafkastore.connection.url=localhost:2181
 kafkastore.topic=_schemas
 debug=false

kafka和zookeeper已经在运行。

为什么来自zookeeper的日志会继续像

一样
[2017-10-17 09:57:31,352] INFO Accepted socket connection from /13.**.**.***:39572 (org.apache.zookeeper.server.NIOServerCnxnFactory)
[2017-10-17 09:57:31,352] WARN Exception causing close of session 0x0 due to java.io.EOFException (org.apache.zookeeper.server.NIOServerCnxn)
[2017-10-17 09:57:31,352] INFO Closed socket connection for client /13.58.108.150:39572 (no session established for client) (org.apache.zookeeper.server.NIOServerCnxn)
[2017-10-17 09:57:31,438] INFO Accepted socket connection from /13.**.**.***:39574 (org.apache.zookeeper.server.NIOServerCnxnFactory)
[2017-10-17 09:57:31,438] WARN Exception causing close of session 0x0 due to java.io.EOFException (org.apache.zookeeper.server.NIOServerCnxn)
[2017-10-17 09:57:31,438] INFO Closed socket connection for client /13.**.***.**:39574 (no session established for client) (org.apache.zookeeper.server.NIOServerCnxn)

我想知道这可能是架构注册失败的原因。

任何建议。

2 个答案:

答案 0 :(得分:1)

NoSuchMethodError表示您的CLASSPATH配置错误。

尚不清楚您正在运行的版本或正在使用的操作系统,但是Windows尚未正式受支持,Confluent Platform的pater版本可能已解决了该问题,或者使用Docker映像也可以正常工作

答案 1 :(得分:0)

在我的情况下,问题是由主机名引起的,检查主机名是否等于“localhost”

问题“方案注册表在启动时失败”

enter image description here

测试解决方案“将主机名设置为”localhost“”

enter image description here

如果这可以解决您的问题,您可以永久配置主机名:

  • 修改文件/ etc / hostname