jojochuang commented on code in PR #8587:
URL: https://github.com/apache/ozone/pull/8587#discussion_r2147219282


##########
hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/service/AbstractKeyDeletingService.java:
##########
@@ -77,6 +79,19 @@ final boolean shouldRun() {
     return !suspended.get() && getOzoneManager().isLeaderReady();
   }
 
+  boolean isPreviousPurgeTransactionFlushed() throws IOException {

Review Comment:
   ```suggestion
     protected boolean isPreviousPurgeTransactionFlushed() throws IOException {
   ```



##########
hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/request/key/OMDirectoriesPurgeRequestWithFSO.java:
##########
@@ -172,17 +171,26 @@ public OMClientResponse 
validateAndUpdateCache(OzoneManager ozoneManager, Execut
           }
         }
         if (path.hasDeletedDir()) {
+          // Using deletedDirInfo since there is no reverse mapping for 
volumeId and bucketId.
+          OmKeyInfo deletedDirInfo = 
omMetadataManager.getDeletedDirTable().get(path.getDeletedDir());
+          if (deletedDirInfo != null) {
+            OmBucketInfo omBucketInfo = getBucketInfo(omMetadataManager,
+                deletedDirInfo.getVolumeName(), 
deletedDirInfo.getBucketName());
+            omBucketInfo.purgePendingDeleteSnapshotNamespace(1);
+          }
           numDirsDeleted++;
         }
       }
       deletingServiceMetrics.incrNumSubDirectoriesMoved(numSubDirMoved);
       deletingServiceMetrics.incrNumSubFilesMoved(numSubFilesMoved);
       deletingServiceMetrics.incrNumDirPurged(numDirsDeleted);
-
+      TransactionInfo transactionInfo = 
TransactionInfo.valueOf(context.getTermIndex());
       if (fromSnapshotInfo != null) {

Review Comment:
   maybe a comment here that the first condition is met when it is purged from 
snapshot, and the second condition is met when purging from active object store.



-- 
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-unsubscr...@ozone.apache.org

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


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

Reply via email to