Chia-Ping Tsai created KAFKA-20089:
--------------------------------------

             Summary: AutoTopicCreationManager should return 
LEADER_NOT_AVAILABLE for in-flight topic creation in KRaft
                 Key: KAFKA-20089
                 URL: https://issues.apache.org/jira/browse/KAFKA-20089
             Project: Kafka
          Issue Type: Bug
            Reporter: Chia-Ping Tsai
            Assignee: Chia-Ping Tsai


from: https://lists.apache.org/thread/5vxgjl7rv4ys6h1z641wqkvh3obtqxvn

When {{auto.create.topics.enable}} is true, calling 
{{consumer.partitionsFor("non-existent-topic")}} behaves differently between ZK 
and KRaft modes.

*ZK Mode:* The client retries and eventually receives the partition info.

*KRaft Mode:* The client receives an empty result (or failure) immediately, as 
it does not retry.

The root cause is that broker returns {{LEADER_NOT_AVAILABLE}} once creating 
the topic on zk. By contrast, broker returns 
{{{}UNKNOWN_TOPIC_OR_PARTITION{}}}, which results in no retry, to client.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to