hadoop-common-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From hair...@apache.org
Subject svn commit: r918624 - in /hadoop/common/trunk: CHANGES.txt src/java/org/apache/hadoop/fs/FsShell.java
Date Wed, 03 Mar 2010 18:49:26 GMT
Author: hairong
Date: Wed Mar  3 18:49:26 2010
New Revision: 918624

URL: http://svn.apache.org/viewvc?rev=918624&view=rev
Log:
HADOOP-6569. FsShell#cat should avoid calling unecessary getFileStatus before opening a file
to read. Contributed by Hairong Kuang.

Modified:
    hadoop/common/trunk/CHANGES.txt
    hadoop/common/trunk/src/java/org/apache/hadoop/fs/FsShell.java

Modified: hadoop/common/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/CHANGES.txt?rev=918624&r1=918623&r2=918624&view=diff
==============================================================================
--- hadoop/common/trunk/CHANGES.txt (original)
+++ hadoop/common/trunk/CHANGES.txt Wed Mar  3 18:49:26 2010
@@ -193,6 +193,9 @@
     HADOOP-6467. Improve the performance on HarFileSystem.listStatus(..).
     (mahadev via szetszwo)
 
+    HADOOP-6569. FsShell#cat should avoid calling unecessary getFileStatus
+    before opening a file to read. (hairong)
+
   BUG FIXES
 
     HADOOP-6293. Fix FsShell -text to work on filesystems other than the

Modified: hadoop/common/trunk/src/java/org/apache/hadoop/fs/FsShell.java
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/src/java/org/apache/hadoop/fs/FsShell.java?rev=918624&r1=918623&r2=918624&view=diff
==============================================================================
--- hadoop/common/trunk/src/java/org/apache/hadoop/fs/FsShell.java (original)
+++ hadoop/common/trunk/src/java/org/apache/hadoop/fs/FsShell.java Wed Mar  3 18:49:26 2010
@@ -350,9 +350,6 @@
     new DelayedExceptionThrowing() {
       @Override
       void process(Path p, FileSystem srcFs) throws IOException {
-        if (srcFs.getFileStatus(p).isDir()) {
-          throw new IOException("Source must be a file.");
-        }
         printToStdout(srcFs.open(p));
       }
     }.globAndProcess(srcPattern, getSrcFileSystem(srcPattern, verifyChecksum));



Mime
View raw message