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

Ayush Saxena commented on HDFS-15093:
-------------------------------------

Thanx [~Harsha1206] for the report. Seems the reason is that at 
{{ClientNamenodeServerSideTranslatorPb}} The Flags are set using else if, so 
only one can be set at one time.


{code:java}
    if(req.getOverwriteDest()) {
      optionList.add(Rename.OVERWRITE);
    } else if(req.hasMoveToTrash()) {
      optionList.add(Rename.TO_TRASH);
    }
{code}

Would upload a fix, removing the else if to check irrespective of presence of 
any other flag.

> RENAME.TO_TRASH is ignored When RENAME.OVERWRITE is specified
> -------------------------------------------------------------
>
>                 Key: HDFS-15093
>                 URL: https://issues.apache.org/jira/browse/HDFS-15093
>             Project: Hadoop HDFS
>          Issue Type: Bug
>            Reporter: Harshakiran Reddy
>            Assignee: Ayush Saxena
>            Priority: Major
>
> When Rename Overwrite flag is specified the To_TRASH option gets silently 
> ignored.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to