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

Chris Nauroth commented on HDFS-6414:
-------------------------------------

Thanks for fixing this, Andrew.  The changes look right to me.  That's a good 
find on the quota problem too.  
{{TestXAttrWithSnapshot#testSetXAttrAfterSnapshotExceedsQuota}} is failing for 
me though.  It's throwing {{NSQuotaExceededException}} on snapshot creation 
instead of on adding the {{XAttrFeature}}.  I expect the test needs to set the 
quota to 3 instead of 2: 1 for the directory + 1 for the file + 1 for the 
snapshot = 3.  Then, adding the {{XAttrFeature}} generates a diff, driving the 
count over 3 and violating the quota.  What do you think?

> xattr modification operations are based on state of latest snapshot instead 
> of current version of inode.
> --------------------------------------------------------------------------------------------------------
>
>                 Key: HDFS-6414
>                 URL: https://issues.apache.org/jira/browse/HDFS-6414
>             Project: Hadoop HDFS
>          Issue Type: Bug
>          Components: namenode
>    Affects Versions: HDFS XAttrs (HDFS-2006)
>            Reporter: Chris Nauroth
>            Assignee: Andrew Wang
>             Fix For: HDFS XAttrs (HDFS-2006)
>
>         Attachments: hdfs-6414.1.patch, hdfs-6414.2.patch
>
>
> {{XAttrStorage#updateINodeXAttrs}} modifies the inode's {{XAttrFeature}} 
> based on reading its current state.  However, the logic for reading current 
> state is incorrect and may instead read the state of the latest snapshot.  If 
> xattrs have been changed after creation of that snapshot, then subsequent 
> xattr operations may yield incorrect results.



--
This message was sent by Atlassian JIRA
(v6.2#6252)

Reply via email to