You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@ozone.apache.org by "sumitagrawl (via GitHub)" <gi...@apache.org> on 2025/11/18 05:54:44 UTC

Re: [PR] HDDS-13723. Add detailed lock information for omMetadataManager locks [ozone]

sumitagrawl commented on code in PR #9157:
URL: https://github.com/apache/ozone/pull/9157#discussion_r2536400284


##########
hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/request/key/OMKeyPurgeRequest.java:
##########
@@ -223,7 +223,9 @@ private List<OmBucketInfo> updateBucketSize(List<BucketPurgeKeysSize> bucketPurg
       }
       return bucketInfoList;
     } finally {
-      mergeOmLockDetails(omMetadataManager.getLock().releaseWriteLocks(BUCKET_LOCK, bucketKeyList));
+      if (acquiredLock) {

Review Comment:
   this is not required as its checked above only if acquiredLock is false and return there only. This is redundant check.



##########
hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/request/key/OMDirectoriesPurgeRequestWithFSO.java:
##########
@@ -254,7 +255,9 @@ public OMClientResponse validateAndUpdateCache(OzoneManager ozoneManager, Execut
           volBucketInfoMap.entrySet()) {
         entry.setValue(entry.getValue().copyObject());
       }
-      omMetadataManager.getLock().releaseWriteLocks(BUCKET_LOCK, bucketLockKeys);

Review Comment:
   the check is already there at top, so this is double check, this is not required.



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