[ https://issues.apache.org/jira/browse/KAFKA-12381?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17293286#comment-17293286 ]
Boyang Chen commented on KAFKA-12381: ------------------------------------- I checked 2.7 code, and we only return INVALID_REPLICATION_FACTOR for internal topics: {code:java} if (isInternal(topic)) { val topicMetadata = createInternalTopic(topic) if (topicMetadata.errorCode == Errors.COORDINATOR_NOT_AVAILABLE.code) metadataResponseTopic(Errors.INVALID_REPLICATION_FACTOR, topic, true, util.Collections.emptyList()) else topicMetadata } else if (allowAutoTopicCreation && config.autoCreateTopicsEnable) { createTopic(topic, config.numPartitions, config.defaultReplicationFactor) } else { metadataResponseTopic(Errors.UNKNOWN_TOPIC_OR_PARTITION, topic, false, util.Collections.emptyList()) } {code} which seems to be lost in the new auto topic creation module. I will try to do a fix there. > Incompatible change in verifiable_producer.log in 2.8 > ----------------------------------------------------- > > Key: KAFKA-12381 > URL: https://issues.apache.org/jira/browse/KAFKA-12381 > Project: Kafka > Issue Type: Bug > Components: core > Affects Versions: 2.8.0 > Reporter: Colin McCabe > Assignee: Boyang Chen > Priority: Blocker > Labels: kip-500 > > In test_verifiable_producer.py , we used to see this error message in > verifiable_producer.log when a topic couldn't be created: > WARN [Producer clientId=producer-1] Error while fetching metadata with > correlation id 1 : {test_topic=LEADER_NOT_AVAILABLE} > (org.apache.kafka.clients.NetworkClient) > The test does a grep LEADER_NOT_AVAILABLE on the log in this case, and it > used to pass. > Now we are instead seeing this in the log file: > WARN [Producer clientId=producer-1] Error while fetching metadata with > correlation id 1 : {test_topic=INVALID_REPLICATION_FACTOR} > (org.apache.kafka.clients.NetworkClient) > And of course now the test fails. > The INVALID_REPLICATION_FACTOR is coming from the new auto topic creation > manager. > It is a simple matter to make the test pass -- I have confirmed that it > passes if we grep for INVALID_REPLICATION_FACTOR in the log file instead of > LEADER_NOT_AVAILABLE. > I think we just need to decide if this change in behavior is acceptable or > not. -- This message was sent by Atlassian Jira (v8.3.4#803005)