dgoyal-confluent commented on code in PR #15359:
URL: https://github.com/apache/kafka/pull/15359#discussion_r2139483544


##########
metadata/src/main/java/org/apache/kafka/controller/PartitionReassignmentReplicas.java:
##########
@@ -120,9 +120,7 @@ Optional<CompletedReassignment> 
maybeCompleteReassignment(List<Integer> targetIs
             }
             if (newTargetReplicas.isEmpty()) return Optional.empty();
         }
-        for (int replica : adding) {
-            if (!newTargetIsr.contains(replica)) return Optional.empty();
-        }
+        if (!newTargetIsr.containsAll(newTargetReplicas)) return 
Optional.empty();

Review Comment:
   If both `"currentReplicas"` and `newTargetReplicas` of a partition under 
reassignment contains a replica that belongs to a demoted broker, then 
`newTargetIsr` would never contain this replica, blocking the completion of an 
actually completed reassignment on the demotion of an unrelated broker. This is 
a blocker for SBC as it would stop balancing till demoted brokers are marked 
otherwise.



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