You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@ozone.apache.org by "aswinshakil (via GitHub)" <gi...@apache.org> on 2024/09/03 20:57:00 UTC

Re: [PR] HDDS-10379. Datanodes should generate initial container merkle tree during container close. [ozone]

aswinshakil commented on code in PR #7065:
URL: https://github.com/apache/ozone/pull/7065#discussion_r1742683516


##########
hadoop-hdds/container-service/src/main/java/org/apache/hadoop/ozone/container/keyvalue/KeyValueHandler.java:
##########
@@ -1259,16 +1283,18 @@ public void quasiCloseContainer(Container container, String reason)
                 .getContainerID() + " while in " + state + " state.", error);
       }
       container.quasiClose();
-      ContainerLogger.logQuasiClosed(container.getContainerData(), reason);
-      sendICR(container);
     } finally {
       container.writeUnlock();
     }
+    createContainerMerkleTree(container);
+    ContainerLogger.logQuasiClosed(container.getContainerData(), reason);
+    sendICR(container);
   }
 
   @Override
   public void closeContainer(Container container)
       throws IOException {
+    createContainerMerkleTree(container);

Review Comment:
   Nice catch. I missed to move in this place. Updating the PR. 



-- 
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: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org