hadoop-hdfs-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Arpit Agarwal (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (HDFS-8831) Trash Support for deletion in HDFS encryption zone
Date Thu, 03 Dec 2015 21:12:11 GMT

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

Arpit Agarwal commented on HDFS-8831:

Hi Xiaoyu, thanks for the updated patch. A few minor comments.

# FileSystem#getTrashRoots can return {{Collection<FileStatus>}} instead of {{FileStatus[]}}.
Sorry I missed this on my last review.
# DistributedFileSystem.java:2329 - Use FileSystem.TRASH_PREFIX instead of ".Trash". Also
lines 2356 and 2363.
# TrashPolicyDefault.java:58 - Use FileSystem.TRASH_PREFIX.
# Nitpick: FileSystem.java:108 - Need space before {{=}}.
# If you think it makes sense, we can add a Javadoc to {{TrashPolicy#getCurrentTrashDir(void)}}
stating it may return an incorrect value if the EZ feature is enabled and the target file
is in an EZ. And callers should prefer {{TrashPolicy#getCurrentTrashDir(Path path)}}.

+1 otherwise.

The  method is not used by our existing tools but it could return an incorrect result 

> Trash Support for deletion in HDFS encryption zone
> --------------------------------------------------
>                 Key: HDFS-8831
>                 URL: https://issues.apache.org/jira/browse/HDFS-8831
>             Project: Hadoop HDFS
>          Issue Type: Sub-task
>          Components: encryption
>            Reporter: Xiaoyu Yao
>            Assignee: Xiaoyu Yao
>         Attachments: HDFS-8831-10152015.pdf, HDFS-8831.00.patch, HDFS-8831.01.patch,
HDFS-8831.02.patch, HDFS-8831.03.patch, HDFS-8831.04.patch
> Currently, "Soft Delete" is only supported if the whole encryption zone is deleted. If
you delete files whinin the zone with trash feature enabled, you will get error similar to
the following 
> {code}
> rm: Failed to move to trash: hdfs://HW11217.local:9000/z1_1/startnn.sh: /z1_1/startnn.sh
can't be moved from an encryption zone.
> {code}
> With HDFS-8830, we can support "Soft Delete" by adding the .Trash folder of the file
being deleted appropriately to the same encryption zone. 

This message was sent by Atlassian JIRA

View raw message