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

Chris Nauroth commented on HDFS-6314:
-------------------------------------

Hi, Yi.  Thanks for writing all of these tests.  I'd like to suggest 2 more 
test cases:

# 1) set xattrs on a file, 2) remove the xattrs from that file, 3) restart NN 
and 4) set xattrs again on that same file.  Do this test twice: once saving a 
checkpoint before the restart and again without saving a checkpoint.  The idea 
here is to make sure that we don't accidentally leave behind a lingering empty 
{{XAttrFeature}} attached to the inode after removal of the xattrs.  That would 
leave the inode in a bad state where future attempts to add xattrs would fail 
due to the precondition check in {{INodeWithAdditionalFields#addXAttrFeature}}. 
 (We had a bug like this on the ACLs feature branch at one time.)
# In {{testXAttrSymlinks}}, let's also do a {{setXAttr}} on the link, and then 
do a {{getXAttrs}} on the target and assert that the xattrs previously set 
through the link are now visible when querying on the target.


> Test cases for XAttrs
> ---------------------
>
>                 Key: HDFS-6314
>                 URL: https://issues.apache.org/jira/browse/HDFS-6314
>             Project: Hadoop HDFS
>          Issue Type: Sub-task
>          Components: test
>    Affects Versions: HDFS XAttrs (HDFS-2006)
>            Reporter: Yi Liu
>            Assignee: Yi Liu
>             Fix For: HDFS XAttrs (HDFS-2006)
>
>         Attachments: HDFS-6314.1.patch, HDFS-6314.patch
>
>
> Tests NameNode interaction for all XAttr APIs, covers restarting NN, saving 
> new checkpoint.
> Tests XAttr for Snapshot, symlinks.
> Tests XAttr for HA failover.
> And more...



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

Reply via email to