siddhantsangwan commented on code in PR #5632:
URL: https://github.com/apache/ozone/pull/5632#discussion_r1411714325


##########
hadoop-hdds/server-scm/src/main/java/org/apache/hadoop/hdds/scm/container/replication/health/DeletingContainerHandler.java:
##########
@@ -70,6 +70,12 @@ public boolean handle(ContainerCheckRequest request) {
     LOG.debug("Checking container {} in DeletingContainerHandler",
         containerInfo);
 

Review Comment:
   I think we also need to increment the `LifeCycleState` as `DELETING` in the 
RM report here? Looks like we missed doing that already.



##########
hadoop-hdds/server-scm/src/main/java/org/apache/hadoop/hdds/scm/container/replication/health/QuasiClosedContainerHandler.java:
##########
@@ -69,15 +72,18 @@ public boolean handle(ContainerCheckRequest request) {
 
     Set<ContainerReplica> replicas = request.getContainerReplicas();
     if (canForceCloseContainer(containerInfo, replicas)) {
-      forceCloseContainer(containerInfo, replicas);
-      return true;
+      if (!request.isReadOnly()) {
+        forceCloseContainer(containerInfo, replicas);
+      }
     } else {
       LOG.debug("Container {} cannot be force closed and is stuck in " +
               "QUASI_CLOSED", containerInfo);
       request.getReport().incrementAndSample(
           ReplicationManagerReport.HealthState.QUASI_CLOSED_STUCK,
           containerInfo.containerID());
     }
+    // Always return false, even if commands were sent. That was, under and
+    // over replication handlers can to check for other issues in the 
container.

Review Comment:
   NIT: typo in javadoc.



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