我运行了这些模块(全部是本地的):
在脚本中有一个send()
电话:
producer = KafkaProducer(bootstrap_servers=['localhost:9092'])
producer.send('test', 'entry1')
每隔15秒左右。
几乎每个send()
调用都会在The Kafka Server上产生这些错误:
[2017-10-16 18:59:10,953] ERROR Closing socket for /127.0.0.1 because of error (kafka.network.Processor)
kafka.common.KafkaException: Wrong request type 16
at kafka.api.RequestKeys$.deserializerForKey(RequestKeys.scala:64)
at kafka.network.RequestChannel$Request.<init>(RequestChannel.scala:50)
at kafka.network.Processor.read(SocketServer.scala:450)
at kafka.network.Processor.run(SocketServer.scala:340)
at java.lang.Thread.run(Thread.java:748)
[2017-10-16 18:59:11,158] INFO Closing socket connection to /127.0.0.1. (kafka.network.Processor)
[2017-10-16 18:59:11,162] INFO Closing socket connection to /127.0.0.1. (kafka.network.Processor)
[2017-10-16 18:59:11,162] ERROR Closing socket for /127.0.0.1 because of error (kafka.network.Processor)
kafka.common.KafkaException: Wrong request type 18
at kafka.api.RequestKeys$.deserializerForKey(RequestKeys.scala:64)
at kafka.network.RequestChannel$Request.<init>(RequestChannel.scala:50)
at kafka.network.Processor.read(SocketServer.scala:450)
at kafka.network.Processor.run(SocketServer.scala:340)
at java.lang.Thread.run(Thread.java:748)
这是一个差不多,因为每5分钟(或多或少)该条目确实可以获得消费者权利,但随后错误将重现。
感谢您的帮助