chia7712 commented on code in PR #18981: URL: https://github.com/apache/kafka/pull/18981#discussion_r2274188359
########## core/src/main/scala/kafka/server/AutoTopicCreationManager.scala: ########## @@ -83,9 +89,30 @@ class DefaultAutoTopicCreationManager( uncreatableTopicResponses ++ creatableTopicResponses } + override def createStreamsInternalTopics( + topics: Map[String, CreatableTopic], + requestContext: RequestContext + ): Unit = { + + for ((_, creatableTopic) <- topics) { + if (creatableTopic.numPartitions() == -1) { + creatableTopic + .setNumPartitions(config.numPartitions) + } + if (creatableTopic.replicationFactor() == -1) { + creatableTopic + .setReplicationFactor(config.defaultReplicationFactor.shortValue) + } + } Review Comment: If `AutoTopicCreationManager` does not specify either partitions or replicas for Streams internal topics, the default values will be determined by the controller's properties, which would be inconsistent with other auto-created topics that is my two cents :) -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: jira-unsubscr...@kafka.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org