sodonnel commented on code in PR #4006:
URL: https://github.com/apache/ozone/pull/4006#discussion_r1035859545
##########
hadoop-hdds/common/src/main/java/org/apache/hadoop/hdds/scm/PlacementPolicy.java:
##########
@@ -60,9 +61,12 @@ List<DatanodeDetails> chooseDatanodes(List<DatanodeDetails>
usedNodes,
* Given a list of datanode and the number of replicas required, return
* a PlacementPolicyStatus object indicating if the container meets the
* placement policy - ie is it on the correct number of racks, etc.
- * @param dns List of datanodes holding a replica of the container
+ * @param dns List of replica holding a replica of the container
* @param replicas The expected number of replicas
*/
ContainerPlacementStatus validateContainerPlacement(
- List<DatanodeDetails> dns, int replicas);
+ List<DatanodeDetails> dns, int replicas);
+ Set<Replica> replicasToCopy(Set<Replica> replicas,
Review Comment:
This needs a Javadoc comment explaining how it works, ie you must pass a set
that is neither over or under replicated, but is mis-replicated. It will return
a Set of replicas to make a copy of else where. If there are none to copy it
should return an empty set, etc.
Also formatting seems to be off on the two lines below.
--
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]