[ 
https://issues.apache.org/jira/browse/HADOOP-2514?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12556129#action_12556129
 ] 

Doug Cutting commented on HADOOP-2514:
--------------------------------------

> if the home directory does not exist, I am proposing that deletes move to a 
> common trash area.

Or the move-to-trash could fail with an exception in this case.

> Also note with the trashbin in /user/<userName>/.trash, instead of 
> /trash/<userName> the trashbin compacter will have to look in multiple home 
> dirs instead of merely in /trash.

Why is that bad?  It'll have to look in the same number of directories in 
either case, no?

> Unfortunately the client side code may find it expensive to do a rpc 
> per-subtree-entry when deleting a large subtree.

It's only an RPC per directory in the tree, not per file.

> Are you suggesting a per-user trashbin compacter running as the user?

No.  But we might have the emptier thread 'su' to each user as it loops through 
the trash directories so that the checking is implicit and only performed once. 
 I don't like using 'su'-like stuff much though.



> Trash and permissions don't mix
> -------------------------------
>
>                 Key: HADOOP-2514
>                 URL: https://issues.apache.org/jira/browse/HADOOP-2514
>             Project: Hadoop
>          Issue Type: New Feature
>          Components: dfs
>    Affects Versions: 0.16.0
>            Reporter: Robert Chansler
>             Fix For: 0.16.0
>
>
> Shell command "rm" is really "mv" to trash with the expectation that the 
> server will at some point really delete the contents of trash. With the 
> advent of permissions, a user can "mv" folders that the user cannot "rm". The 
> present trash feature as implemented would allow the user to suborn the 
> server into deleting a folder in violation of the permissions model.
> A related issue is that if anybody can mv a folder to the trash anybody else 
> can mv that same folder from the trash. This may be contrary to the 
> expectations of the user.
> What is a better model for trash?

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to