chia7712 commented on code in PR #23858:
URL: https://github.com/apache/kafka/pull/23858#discussion_r4554006732


##########
metadata/src/main/java/org/apache/kafka/controller/ReplicationControlManager.java:
##########
@@ -1989,12 +1989,11 @@ void createPartitions(ControllerRequestContext context,
                 additional, e.throttleTimeMs());
             throw e;
         }
-        Iterator<PartitionRegistration> iterator = 
topicInfo.parts.values().iterator();
-        if (!iterator.hasNext()) {
+        PartitionRegistration partitionInfo = topicInfo.parts.get(0);

Review Comment:
   > I also found a related bug. While partition 0 is being reassigned, its 
replica list holds both the old and the new replicas, so createPartitions gives 
new partitions too many replicas. I would like to open a separate JIRA for it. 
WDYT?
   
   Nice find. Yes, please open a ticket for it.



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

Reply via email to