Details
-
Improvement
-
Status: Resolved
-
Major
-
Resolution: Duplicate
-
None
-
None
-
None
Description
//StreamFile.doGet(..) long fileLen = dfs.getFileInfo(filename).getLen(); FSInputStream in = dfs.open(filename);
In the codes above, t is unnecessary to call getFileInfo(..), which is an additional RPC to namenode. The file length can be obtained from the input stream after open(..).
Attachments
Issue Links
- is part of
-
HDFS-1085 hftp read failing silently
-
- Closed
-