confluentinc / confluent-kafka-dotnet

Confluent's Apache Kafka .NET client
https://github.com/confluentinc/confluent-kafka-dotnet/wiki
Apache License 2.0
60 stars 862 forks source link

C#.NET Confluent Kafka Error: Disconnected (after XYZms in state UP) #2198

Open ShaibalKantiShil opened 6 months ago

ShaibalKantiShil commented 6 months ago

Description

Application connects properly with the Kafka broker. But, sometimes, we get an error similar to: “Disconnected (after XYZms in state UP)” Once this error is thrown, the Kafka consumer stops polling Kafka. The error is not re-tried automatically.

How to reproduce

Unsure. This error happens randomly.

Checklist

Please provide the following information:

anchitj commented 4 months ago

Do you have any debug logs available?

ShaibalKantiShil commented 4 months ago

Hello @anchitj, please find the related redacted error log attached. 2024-03-14 - Redacted.txt

christian-ber commented 1 month ago

I believe we have the same issue. This happens after consumer is idle for a longer period.

Librdkafka: [thrd:app]: <redacted>#consumer-1: sasl_ssl://<broker-url>:9092/2: Disconnected (after 117130718ms in state UP) After this message is logged, no messages are consumed until the service is restarted.

We're using: Confluent.Kafka" Version="2.5.2"