You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jira@kafka.apache.org by GitBox <gi...@apache.org> on 2020/11/19 06:13:38 UTC

[GitHub] [kafka] chia7712 commented on a change in pull request #9435: KAFKA-10606: Disable auto topic creation for fetch-all-topic-metadata request

chia7712 commented on a change in pull request #9435:
URL: https://github.com/apache/kafka/pull/9435#discussion_r526616584



##########
File path: core/src/main/scala/kafka/server/KafkaApis.scala
##########
@@ -1333,7 +1343,17 @@ class KafkaApis(val requestChannel: RequestChannel,
       }
     }
 
-    val completeTopicMetadata = topicMetadata ++ unauthorizedForCreateTopicMetadata ++ unauthorizedForDescribeTopicMetadata
+    val completeTopicMetadata = (if (metadataRequest.isAllTopics) {

Review comment:
       Could we do this filter early? For example, how about filtering ```getTopicMetadata``` directly? That makes all fixes be in one place and following authorized ops can skip "unknown partition/topic" as well.




----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org