vsinghal85 commented on code in PR #4117:
URL: https://github.com/apache/gobblin/pull/4117#discussion_r2099552892


##########
gobblin-utility/src/main/java/org/apache/gobblin/util/HadoopUtils.java:
##########
@@ -783,14 +816,21 @@ public static void ensureDirectoryExists(FileSystem fs, 
Path path, Iterator<Owne
       OwnerAndPermission ownerAndPermission = 
ownerAndPermissionIterator.next();
 
       if (path.getParent() != null) {
-        ensureDirectoryExists(fs, path.getParent(), 
ownerAndPermissionIterator, failIfOwnerSetFails);
+        ensureDirectoryExists(fs, path.getParent(), 
ownerAndPermissionIterator, failIfOwnerSetFails, copyOnlySourceAclToDest);
       }
 
       if (!fs.mkdirs(path)) {
         // fs.mkdirs returns false if path already existed. Do not overwrite 
permissions
         return;
       }
-
+      try {
+        if (copyOnlySourceAclToDest) {
+          fs.removeAcl(path);

Review Comment:
   removeDefaultAcl only removes default ACL's, in ACL inheritance default 
ACL's are inherited as well as default ACL's are inherited as direct ACL's they 
also need to be removed, so removeAcl removes all ACL's.
   
   Anyway other permissions later on in the code are being overwritten so we 
need not worry about them.



-- 
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: dev-unsubscr...@gobblin.apache.org

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

Reply via email to