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 2022/04/01 00:16:15 UTC
[GitHub] [kafka] cmccabe commented on a change in pull request #11910: KAFKA-13743: Prevent topics with conflicting metrics names from being created in KRaft mode
cmccabe commented on a change in pull request #11910:
URL: https://github.com/apache/kafka/pull/11910#discussion_r840122353
##########
File path: metadata/src/main/java/org/apache/kafka/controller/ReplicationControlManager.java
##########
@@ -548,6 +550,15 @@ static void validateNewTopicNames(Map<String, ApiError> topicErrors,
topicErrors.put(topic.name(),
new ApiError(Errors.INVALID_TOPIC_EXCEPTION, e.getMessage()));
}
+ if (Topic.hasCollisionChars(topic.name())) {
Review comment:
We shouldn't loop through all topics in the cluster here. This could be a very long list. Instead, let's keep a separate "potentially colliding names" set of strings where all the colliding characters are translated to a single character.
--
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-unsubscribe@kafka.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org