sodonnel commented on code in PR #3640:
URL: https://github.com/apache/ozone/pull/3640#discussion_r934402045


##########
hadoop-hdds/server-scm/src/main/java/org/apache/hadoop/hdds/scm/container/replication/ECUnderReplicationHandler.java:
##########
@@ -186,15 +191,17 @@ public Map<DatanodeDetails, SCMCommand<?>> 
processAndCreateCommands(
       Set<Integer> decomIndexes = 
replicaCount.decommissioningOnlyIndexes(true);
       if (decomIndexes.size() > 0) {
         final List<DatanodeDetails> selectedDatanodes =
-            getTargetDatanodes(replicas, container, decomIndexes.size());
+            getTargetDatanodes(excludedNodes, container, decomIndexes.size());
+        excludedNodes.addAll(selectedDatanodes);

Review Comment:
   There are two reasons I added it here - (1) to keep it consistent with the 
earlier code and (2) because we need to extend this class for maintenance mode, 
and we will need to add it here then anyway, and its something that could 
easily get missed. Therefore I think its best to keep it as it is.



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


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to