hadoop-common-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "dhruba borthakur (JIRA)" <j...@apache.org>
Subject [jira] Commented: (HADOOP-1453) exists() not necessary before DFS.open
Date Tue, 19 Jun 2007 00:21:26 GMT

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

dhruba borthakur commented on HADOOP-1453:
------------------------------------------

Both your patches are for DistributedFileSystem whereas your comment says that there are *two*
places where a redundant exists()  call is made: DistributedFileSystem and ChecksumFileSystem.
Can you pl clarify?

> exists() not necessary before DFS.open
> --------------------------------------
>
>                 Key: HADOOP-1453
>                 URL: https://issues.apache.org/jira/browse/HADOOP-1453
>             Project: Hadoop
>          Issue Type: Bug
>          Components: dfs
>            Reporter: Raghu Angadi
>            Assignee: Raghu Angadi
>             Fix For: 0.14.0
>
>         Attachments: HADOOP-1453-01.patch, HADOOP-1453-02.patch
>
>
> {code:title=DistributedFileSystem.java:131|borderStyle=solid}
> public FSDataInputStream open(Path f, int bufferSize) throws IOException {
>       if (!exists(f)) {
>         throw new FileNotFoundException(f.toString());
>       }
>       return new DFSClient.DFSDataInputStream(dfs.open(getPath(f)), bufferSize);
>  }
> {code}
> {{exists(f)}} adds extra namenode interaction that is not really required. Open is a
critical DFS call.

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


Mime
View raw message