Tejaskriya commented on code in PR #5929:
URL: https://github.com/apache/ozone/pull/5929#discussion_r1461487571
##########
hadoop-hdds/server-scm/src/main/java/org/apache/hadoop/hdds/scm/node/DatanodeAdminMonitorImpl.java:
##########
@@ -398,6 +398,12 @@ private boolean checkPipelinesClosedOnNode(TrackedNode dn)
private boolean checkContainersReplicatedOnNode(TrackedNode dn)
throws NodeNotFoundException {
+ Map<String, List<ContainerID>> containerOnDn =
getContainersReplicatedOnNode(dn, true);
+ return (containerOnDn.get("UnderReplicated").size() == 0) &&
(containerOnDn.get("UnClosed").size() == 0);
+ }
+
+ public Map<String, List<ContainerID>>
getContainersReplicatedOnNode(TrackedNode dn, boolean updateMetrics)
Review Comment:
I have followed your suggestion to save the lists of ContainerIDs in
TrackedNode as a Map at the end of `checkContainersReplicatedOnNode` and
`getContainersReplicatedOnNode` only retrieves this Map.
Currently, for the time period in which the node is scheduled for
decommissioning but hasn't been checked yet, an empty map is shown in the place
for the container IDs.
Could you please review the PR with these recent changes?
--
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]