[jira] [Updated] (HDFS-5476) Snapshot: clean the blocks/files/directories under a renamed file/directory while deletion
[ https://issues.apache.org/jira/browse/HDFS-5476?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Jing Zhao updated HDFS-5476: Priority: Major (was: Blocker) Fix Version/s: (was: 2.4.0) 2.3.0 I've merged this to branch-2.3 > Snapshot: clean the blocks/files/directories under a renamed file/directory > while deletion > -- > > Key: HDFS-5476 > URL: https://issues.apache.org/jira/browse/HDFS-5476 > Project: Hadoop HDFS > Issue Type: Bug >Affects Versions: 2.2.0 >Reporter: Jing Zhao >Assignee: Jing Zhao > Fix For: 2.3.0 > > Attachments: HDFS-5476.001.patch > > > Currently DstReference#destroyAndCollectBlocks may fail to clean the subtree > under the DstReference node for file/directory/snapshot deletion. > Use case 1: > # rename under-construction file with 0-sized blocks after snapshot. > # delete the renamed directory. > We need to make sure we delete the 0-sized block. > Use case 2: > # create snapshot s0 for / > # create a new file under /foo/bar/ > # rename foo --> foo2 > # create snapshot s1 > # delete bar and foo2 > # delete snapshot s1 > We need to make sure we delete the file under /foo/bar since it is not > included in snapshot s0. -- This message was sent by Atlassian JIRA (v6.1.4#6159)
[jira] [Updated] (HDFS-5476) Snapshot: clean the blocks/files/directories under a renamed file/directory while deletion
[ https://issues.apache.org/jira/browse/HDFS-5476?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Jing Zhao updated HDFS-5476: Priority: Blocker (was: Major) Target Version/s: 2.2.1 > Snapshot: clean the blocks/files/directories under a renamed file/directory > while deletion > -- > > Key: HDFS-5476 > URL: https://issues.apache.org/jira/browse/HDFS-5476 > Project: Hadoop HDFS > Issue Type: Bug >Affects Versions: 2.2.0 >Reporter: Jing Zhao >Assignee: Jing Zhao >Priority: Blocker > Fix For: 2.3.0 > > Attachments: HDFS-5476.001.patch > > > Currently DstReference#destroyAndCollectBlocks may fail to clean the subtree > under the DstReference node for file/directory/snapshot deletion. > Use case 1: > # rename under-construction file with 0-sized blocks after snapshot. > # delete the renamed directory. > We need to make sure we delete the 0-sized block. > Use case 2: > # create snapshot s0 for / > # create a new file under /foo/bar/ > # rename foo --> foo2 > # create snapshot s1 > # delete bar and foo2 > # delete snapshot s1 > We need to make sure we delete the file under /foo/bar since it is not > included in snapshot s0. -- This message was sent by Atlassian JIRA (v6.1#6144)
[jira] [Updated] (HDFS-5476) Snapshot: clean the blocks/files/directories under a renamed file/directory while deletion
[ https://issues.apache.org/jira/browse/HDFS-5476?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Jing Zhao updated HDFS-5476: Resolution: Fixed Fix Version/s: 2.3.0 Status: Resolved (was: Patch Available) Thanks for the review, Nicholas and Vinay! I've committed this to trunk and branch-2. > Snapshot: clean the blocks/files/directories under a renamed file/directory > while deletion > -- > > Key: HDFS-5476 > URL: https://issues.apache.org/jira/browse/HDFS-5476 > Project: Hadoop HDFS > Issue Type: Bug >Affects Versions: 2.2.0 >Reporter: Jing Zhao >Assignee: Jing Zhao > Fix For: 2.3.0 > > Attachments: HDFS-5476.001.patch > > > Currently DstReference#destroyAndCollectBlocks may fail to clean the subtree > under the DstReference node for file/directory/snapshot deletion. > Use case 1: > # rename under-construction file with 0-sized blocks after snapshot. > # delete the renamed directory. > We need to make sure we delete the 0-sized block. > Use case 2: > # create snapshot s0 for / > # create a new file under /foo/bar/ > # rename foo --> foo2 > # create snapshot s1 > # delete bar and foo2 > # delete snapshot s1 > We need to make sure we delete the file under /foo/bar since it is not > included in snapshot s0. -- This message was sent by Atlassian JIRA (v6.1#6144)
[jira] [Updated] (HDFS-5476) Snapshot: clean the blocks/files/directories under a renamed file/directory while deletion
[ https://issues.apache.org/jira/browse/HDFS-5476?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Tsz Wo (Nicholas), SZE updated HDFS-5476: - Hadoop Flags: Reviewed +1 patch looks good. > Snapshot: clean the blocks/files/directories under a renamed file/directory > while deletion > -- > > Key: HDFS-5476 > URL: https://issues.apache.org/jira/browse/HDFS-5476 > Project: Hadoop HDFS > Issue Type: Bug >Affects Versions: 2.2.0 >Reporter: Jing Zhao >Assignee: Jing Zhao > Attachments: HDFS-5476.001.patch > > > Currently DstReference#destroyAndCollectBlocks may fail to clean the subtree > under the DstReference node for file/directory/snapshot deletion. > Use case 1: > # rename under-construction file with 0-sized blocks after snapshot. > # delete the renamed directory. > We need to make sure we delete the 0-sized block. > Use case 2: > # create snapshot s0 for / > # create a new file under /foo/bar/ > # rename foo --> foo2 > # create snapshot s1 > # delete bar and foo2 > # delete snapshot s1 > We need to make sure we delete the file under /foo/bar since it is not > included in snapshot s0. -- This message was sent by Atlassian JIRA (v6.1#6144)
[jira] [Updated] (HDFS-5476) Snapshot: clean the blocks/files/directories under a renamed file/directory while deletion
[ https://issues.apache.org/jira/browse/HDFS-5476?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Jing Zhao updated HDFS-5476: Status: Patch Available (was: Open) > Snapshot: clean the blocks/files/directories under a renamed file/directory > while deletion > -- > > Key: HDFS-5476 > URL: https://issues.apache.org/jira/browse/HDFS-5476 > Project: Hadoop HDFS > Issue Type: Bug >Affects Versions: 2.2.0 >Reporter: Jing Zhao >Assignee: Jing Zhao > Attachments: HDFS-5476.001.patch > > > Currently DstReference#destroyAndCollectBlocks may fail to clean the subtree > under the DstReference node for file/directory/snapshot deletion. > Use case 1: > # rename under-construction file with 0-sized blocks after snapshot. > # delete the renamed directory. > We need to make sure we delete the 0-sized block. > Use case 2: > # create snapshot s0 for / > # create a new file under /foo/bar/ > # rename foo --> foo2 > # create snapshot s1 > # delete bar and foo2 > # delete snapshot s1 > We need to make sure we delete the file under /foo/bar since it is not > included in snapshot s0. -- This message was sent by Atlassian JIRA (v6.1#6144)
[jira] [Updated] (HDFS-5476) Snapshot: clean the blocks/files/directories under a renamed file/directory while deletion
[ https://issues.apache.org/jira/browse/HDFS-5476?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Jing Zhao updated HDFS-5476: Attachment: HDFS-5476.001.patch Upload the initial patch including two unit tests to reproduce the two use cases described above. > Snapshot: clean the blocks/files/directories under a renamed file/directory > while deletion > -- > > Key: HDFS-5476 > URL: https://issues.apache.org/jira/browse/HDFS-5476 > Project: Hadoop HDFS > Issue Type: Bug >Affects Versions: 2.2.0 >Reporter: Jing Zhao >Assignee: Jing Zhao > Attachments: HDFS-5476.001.patch > > > Currently DstReference#destroyAndCollectBlocks may fail to clean the subtree > under the DstReference node for file/directory/snapshot deletion. > Use case 1: > # rename under-construction file with 0-sized blocks after snapshot. > # delete the renamed directory. > We need to make sure we delete the 0-sized block. > Use case 2: > # create snapshot s0 for / > # create a new file under /foo/bar/ > # rename foo --> foo2 > # create snapshot s1 > # delete bar and foo2 > # delete snapshot s1 > We need to make sure we delete the file under /foo/bar since it is not > included in snapshot s0. -- This message was sent by Atlassian JIRA (v6.1#6144)