tzssangglass commented on issue #6033:
URL: https://github.com/apache/apisix/issues/6033#issuecomment-1008558652
> If I start kafka with docker, shut down the container after starting it
and start it again, can I simulate the broker down scenario you mentioned
@guxingke I was unable to reproduce the scenario with this on the master
branch.
Here is my configuration of route:
```
{
"plugins": {
"kafka-logger": {
"broker_list": {
"127.0.0.1": 9092
},
"kafka_topic": "apisix_traffic_logs",
"key": "key1",
"timeout": 1,
"batch_max_size": 1
}
},
"upstream": {
"nodes": {
"127.0.0.1:1980": 1
},
"type": "roundrobin"
},
"uri": "/hello"
}
```
Here is my exception log:
```
2022/01/10 13:36:36 [error] 18553#25478878: *43867 [lua] client.lua:150:
refresh(): all brokers failed in fetch topic metadata, context: ngx.timer,
client: 127.0.0.1, server: 0.0.0.0:9080
2022/01/10 13:36:36 [error] 18553#25478878: *43867 [lua] client.lua:150:
refresh(): all brokers failed in fetch topic metadata, context: ngx.timer,
client: 127.0.0.1, server: 0.0.0.0:9080
2022/01/10 13:36:36 [error] 18553#25478878: *43867 [lua] client.lua:150:
refresh(): all brokers failed in fetch topic metadata, context: ngx.timer,
client: 127.0.0.1, server: 0.0.0.0:9080
2022/01/10 13:36:36 [error] 18553#25478878: *43867 [lua] producer.lua:272:
buffered messages send to kafka err: connection refused, retryable: true,
topic: apisix_traffic_logs, partition_id: 0, length: 1, context: ngx.timer,
client: 127.0.0.1, server: 0.0.0.0:9080
```
When I restarted the kafka container, it continued to push messages to kafka
normally again.
Note: I did not make the kafka volume, and the restarted kafka is a new
cluster.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]