ChenSammi commented on a change in pull request #1162: URL: https://github.com/apache/hadoop-ozone/pull/1162#discussion_r452052352
########## File path: hadoop-hdds/server-scm/src/main/java/org/apache/hadoop/hdds/scm/container/ReplicationManager.java ########## @@ -543,11 +543,15 @@ private void handleUnderReplicatedContainer(final ContainerInfo container, List<DatanodeDetails> targetReplicas = new ArrayList<>(source); // Then add any pending additions targetReplicas.addAll(replicationInFlight); - - int delta = replicationFactor - getReplicaCount(id, replicas); final ContainerPlacementStatus placementStatus = containerPlacement.validateContainerPlacement( targetReplicas, replicationFactor); + int delta = replicationFactor - getReplicaCount(id, replicas); + if (placementStatus.isPolicySatisfied() && delta <= 0) { Review comment: Make sense. ---------------------------------------------------------------- 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: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: ozone-issues-unsubscr...@hadoop.apache.org For additional commands, e-mail: ozone-issues-h...@hadoop.apache.org