ashvina commented on a change in pull request #1478: HDFS-14856 Fetch file ACLs while mounting external store URL: https://github.com/apache/hadoop/pull/1478#discussion_r326831492
########## File path: hadoop-tools/hadoop-fs2img/src/main/java/org/apache/hadoop/hdfs/server/namenode/FSTreeWalk.java ########## @@ -71,14 +95,24 @@ private FSTreeIterator() { } FSTreeIterator(TreePath p) { + AclStatus acls = null; + Path remotePath = p.getFileStatus().getPath(); + try { + acls = getAclStatus(fs, remotePath); + } catch (IOException e) { + LOG.warn( + "Got exception when trying to get remote acls for path {} : {}", + remotePath, e.getMessage()); + } getPendingQueue().addFirst( - new TreePath(p.getFileStatus(), p.getParentId(), this, fs)); + new TreePath(p.getFileStatus(), p.getParentId(), this, fs, acls)); } FSTreeIterator(Path p) throws IOException { try { FileStatus s = fs.getFileStatus(root); - getPendingQueue().addFirst(new TreePath(s, -1L, this, fs)); + AclStatus acls = getAclStatus(fs, s.getPath()); Review comment: Good catch. The scanner will not fail if the remote FS does not support ACLs. All other IOException fail the operation in all paths now. Thanks ! ---------------------------------------------------------------- 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. For queries about this service, please contact Infrastructure at: us...@infra.apache.org With regards, Apache Git Services --------------------------------------------------------------------- To unsubscribe, e-mail: common-issues-unsubscr...@hadoop.apache.org For additional commands, e-mail: common-issues-h...@hadoop.apache.org