[ 
https://issues.apache.org/jira/browse/HDFS-7078?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14138296#comment-14138296
 ] 

Colin Patrick McCabe commented on HDFS-7078:
--------------------------------------------

{code}
+      // Skip EZs that are only present in snapshots
+      // Re-resolve the path, see if the current inode ID matches the EZ map's 
+      // inode ID
+      final String pathName = getFullPathName(ezi); <========
+      INodesInPath iip = dir.getINodesInPath(pathName, false);
+      INode lastINode = iip.getLastINode();
+      if (lastINode == null || lastINode.getId() != ezi.getINodeId()) {
+        continue;
+      }
{code}

Can you add a comment here explaining that getFullPathName never returns a path 
to a snapshot directory?

+1 after that's addressed (and jenkins runs)

> Fix listEZs to work correctly with snapshots
> --------------------------------------------
>
>                 Key: HDFS-7078
>                 URL: https://issues.apache.org/jira/browse/HDFS-7078
>             Project: Hadoop HDFS
>          Issue Type: Sub-task
>          Components: encryption
>    Affects Versions: 2.6.0
>            Reporter: Andrew Wang
>            Assignee: Andrew Wang
>         Attachments: hdfs-7078.001.patch
>
>
> listEZs will list encryption zones that are only present in a snapshot, 
> rather than only the EZs in the current filesystem state.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to