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
I try to connect the producer to Kafka brokers with SASL. My Kafka cluster has 4 brokers and every topic has 10 partitions. This is the symptom:
The first produce call is slow and it costs exactly 1 minute.
Other messages are fast, but sometimes it will slow again (and costs exactly 1 minute).
The log I printed out at the time query is slowed shows that the client periodically tries to get the metadata from brokers because the reason "leader is down: re-query". It just happens when I try to produce messages.
I have solved this issue. Here is the investigation.
TL,DR: it is because of the kinit command took a long time to run (1 minute exactly).
The reason is:
kinit query runs in 1 minute. The reason because of in the krb5.conf file, flag dns_lookup_kdc is true. Set it to false can solve this problem. Reference
while kinit runs, state of brokers moves to AUTH_LEGACY.
This causes the job that runs every 1 second triggers to query the topic meta . data, but it cannot.
I try to connect the producer to Kafka brokers with SASL. My Kafka cluster has 4 brokers and every topic has 10 partitions. This is the symptom:
The log I printed out at the time query is slowed shows that the client periodically tries to get the metadata from brokers because the reason "leader is down: re-query". It just happens when I try to produce messages.
Below is the detail log data:
Based on this symptom I guess:
Checklist
IMPORTANT: We will close issues where the checklist has not been completed.
Please provide the following information:
<REPLACE with e.g., v0.10.5 or a git sha. NOT "latest" or "current">
<REPLACE with e.g., 0.10.2.3>
<REPLACE with e.g., message.timeout.ms=123, auto.reset.offset=earliest, ..>
<REPLACE with e.g., Centos 5 (x64)>
debug=..
as necessary) from librdkafkaThe text was updated successfully, but these errors were encountered: