You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[sarama] 2023/06/18 18:12:34 tryRefreshMetadata(): client/metadata fetching metadata for [__consumer_offsets] from broker 10.8.13.1:9092
[sarama] 2023/06/18 18:12:34 tryRefreshMetadata(): successfully fetched metadata for topics.
[sarama] 2023/06/18 18:12:34 Unexpected topic-level metadata error: kafka server: Replication-factor is invalid.
[sarama] 2023/06/18 18:12:34 ERROR: tryRefreshMetadata(): successfully fetched metadata but failed on updateMetadata, err: kafka server: Replication-factor is invalid.
[sarama] 2023/06/18 18:12:34 ERROR: client/coordinator the __consumer_offsets topic is not initialized completely yet. Waiting 2 seconds...
[sarama] 2023/06/18 18:12:34 tryRefreshMetadata(): successfully fetched metadata for topics.
[sarama] 2023/06/18 18:12:34 Unexpected topic-level metadata error: kafka server: Replication-factor is invalid.
[sarama] 2023/06/18 18:12:34 ERROR: tryRefreshMetadata(): successfully fetched metadata but failed on updateMetadata, err: kafka server: Replication-factor is invalid.
[sarama] 2023/06/18 18:12:34 ERROR: client/coordinator the __consumer_offsets topic is not initialized completely yet. Waiting 2 seconds...
Problem Description
Within client.go::findCoordinator() and tryRefreshMetadata(), it asks anyBroker() for the endpoint of the request. anyBroker() will return the same endpoint (first one of the client.seedBrokers list). This is an issue if the chosen endpoint is misconfigured (it will return a error response). In this use case, the broker is not evicted from the client.seedBrokers list.
Could anyBroker() be more resilient with the following enhancement?
What is the downside of anyBroker() returning a random endpoint from client.seedBrokers()?
Although the code gives the appearance of always choosing the first seed broker, there are a few code paths that randomise the seed brokers slice via client.randomizeSeedBrokers such that this should be a different order at various points in time
Thank you for taking the time to raise this issue. However, it has not had any activity on it in the past 90 days and will be closed in 30 days if no updates occur.
Please check if the main branch has already resolved the issue since it was raised. If you believe the issue is still valid and you would like input from the maintainers then please comment to ask for it to be reviewed.
I believe that the changes made under #2645 have improved this area so I'm going to go ahead and close this issue as fixed by that. Feel free to re-open if you have further concerns
Versions
Configuration
What configuration values are you using for Sarama and Kafka?
Logs
Problem Description
Within client.go::findCoordinator() and tryRefreshMetadata(), it asks anyBroker() for the endpoint of the request. anyBroker() will return the same endpoint (first one of the client.seedBrokers list). This is an issue if the chosen endpoint is misconfigured (it will return a error response). In this use case, the broker is not evicted from the client.seedBrokers list.
Could anyBroker() be more resilient with the following enhancement?
The text was updated successfully, but these errors were encountered: