neils-dev commented on code in PR #4439:
URL: https://github.com/apache/ozone/pull/4439#discussion_r1147056171


##########
hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/OzoneAclUtils.java:
##########
@@ -116,6 +100,18 @@ public static void checkAllAcls(OmMetadataReader 
omMetadataReader,
     // volume owner if current ugi user is volume owner else we need check
     //{OWNER} equals bucket owner for bucket/key/prefix.
     case PREFIX:
+      //OzoneNativeAuthorizer differs from Ranger Authorizer as Ranger requires
+      // only READ access on parent level access. OzoneNativeAuthorizer has
+      // different parent level access based on the child level access type
+      IAccessAuthorizer.ACLType parentAclRight = 
IAccessAuthorizer.ACLType.READ;
+      if (omMetadataReader.isNativeAuthorizerEnabled()) {

Review Comment:
   can be rewritten as conditional, 
   ```
   if (omMetadataReader.isNativeAuthorizerEnabled() && resType == BUCKET) {
     parentAclRight = getParentNativeAcl(...
   }
   ```



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