You are viewing a plain text version of this content. The canonical link for it is here.
Posted to common-issues@hadoop.apache.org by "Brahma Reddy Battula (JIRA)" <ji...@apache.org> on 2016/08/04 07:45:20 UTC

[jira] [Commented] (HADOOP-13236) truncate will fail when we use viewfilesystem

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

Brahma Reddy Battula commented on HADOOP-13236:
-----------------------------------------------

[~arpitagarwal] can you take look at last patch,if you get time..?

> truncate will fail when we use viewfilesystem
> ---------------------------------------------
>
>                 Key: HADOOP-13236
>                 URL: https://issues.apache.org/jira/browse/HADOOP-13236
>             Project: Hadoop Common
>          Issue Type: Bug
>            Reporter: Brahma Reddy Battula
>            Assignee: Brahma Reddy Battula
>         Attachments: HADOOP-13236-002.patch, HADOOP-13236.patch
>
>
> truncate will fail when use viewFS.
> {code}
>   @Override
>   public boolean truncate(final Path f, final long newLength)
>       throws IOException {
>     InodeTree.ResolveResult<FileSystem> res =
>         fsState.resolve(getUriPath(f), true);
>     return res.targetFileSystem.truncate(f, newLength);
>   }
>   {code}
>  *Path should be like below:* 
> {{return res.targetFileSystem.truncate(f, newLength);}}  *should be*  {{return res.targetFileSystem.truncate(res.remainingPath, newLength);}}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: common-issues-unsubscribe@hadoop.apache.org
For additional commands, e-mail: common-issues-help@hadoop.apache.org