doujiang24 / lua-resty-kafka

Lua kafka client driver for the Openresty based on the cosocket API
BSD 3-Clause "New" or "Revised" License
801 stars 274 forks source link

Failed authentication with /xxx (Unexpected Kafka request of type PRODUCE during SASL handshake.) #118

Closed wuare closed 2 years ago

wuare commented 2 years ago

各位: 有没人使用的时候遇到这种报错,使用sasl认证 Kafka服务端报错 Failed authentication with /xxx (Unexpected Kafka request of type PRODUCE during SASL handshake.)

lua-resty-kafka报错 producer.lua:271: buffered messages send to kafka err: closed, retryable: true, topic: test, partition_id: 0, length: 2, context: ngx.timer, client: xxx, server: 0.0.0.0:9080

我运行了很多次,只有1-2次是正常发送消息,大部分情况都在报这个错

kafka版本:2.6.1 lua-resty-kafka版本:master

wuare commented 2 years ago

image 感觉是这个判断条件引发的错误,只是猜测

biubiue commented 2 years ago

I reslove this problem, please see lua-resty-kafka