robobario commented on code in PR #20340:
URL: https://github.com/apache/kafka/pull/20340#discussion_r2269097484
##########
core/src/main/scala/kafka/server/AutoTopicCreationManager.scala:
##########
@@ -138,6 +138,18 @@ class DefaultAutoTopicCreationManager(
} else if (response.versionMismatch() != null) {
warn(s"Auto topic creation failed for ${creatableTopics.keys} with
invalid version exception")
} else {
+ if (response.hasResponse) {
+ response.responseBody() match {
+ case produceResponse: CreateTopicsResponse =>
+ produceResponse.data().topics().forEach(topicResult => {
+ val error = Errors.forCode(topicResult.errorCode())
+ if (error != Errors.NONE) {
+ warn(s"Auto topic creation failed for
${topicResult.name()} with error '${error.name()}':
${topicResult.errorMessage()}")
+ }
+ })
+ case _ => // do nothing
Review Comment:
true, have added a warn log in this case
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]