smengcl commented on code in PR #10859:
URL: https://github.com/apache/ozone/pull/10859#discussion_r3647880484


##########
hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/OzoneManager.java:
##########
@@ -3078,6 +3080,18 @@ private OmBucketInfo getResolvedSourceBucket(
         return cachedSource;
       }
     }
+    if (getAclsEnabled()) {
+      try {
+        omMetadataReader.checkAcls(ResourceType.BUCKET, StoreType.OZONE,
+            ACLType.READ, resolvedBucket.realVolume(),
+            resolvedBucket.realBucket(), null);
+      } catch (OMException e) {
+        if (e.getResult() == PERMISSION_DENIED) {
+          return null;

Review Comment:
   I think the reason Codex did that was because of this:
   
   
https://github.com/apache/ozone/blob/77ceb2969b507096fe97482da3a1e693ccc64561/hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/OzoneManager.java#L3011-L3018
   
   `listBuckets` is doing a best-effort resolution of the links. If it hits 
`PERMISSION_DENIED`, it will leave that OmBucketInfo untouched



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