hadoop-common-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tomwh...@apache.org
Subject svn commit: r770681 - in /hadoop/core/trunk: CHANGES.txt src/core/org/apache/hadoop/fs/s3native/NativeS3FileSystem.java
Date Fri, 01 May 2009 13:43:10 GMT
Author: tomwhite
Date: Fri May  1 13:43:10 2009
New Revision: 770681

URL: http://svn.apache.org/viewvc?rev=770681&view=rev
Log:
HADOOP-5656. Counter for S3N Read Bytes does not work. Contributed by Ian Nowland.

Modified:
    hadoop/core/trunk/CHANGES.txt
    hadoop/core/trunk/src/core/org/apache/hadoop/fs/s3native/NativeS3FileSystem.java

Modified: hadoop/core/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/hadoop/core/trunk/CHANGES.txt?rev=770681&r1=770680&r2=770681&view=diff
==============================================================================
--- hadoop/core/trunk/CHANGES.txt (original)
+++ hadoop/core/trunk/CHANGES.txt Fri May  1 13:43:10 2009
@@ -474,6 +474,9 @@
     HADOOP-5592. Fix typo in Streaming doc in reference to GzipCodec.
     (Corinne Chandel via tomwhite)
 
+    HADOOP-5656. Counter for S3N Read Bytes does not work. (Ian Nowland
+    via tomwhite)
+
 Release 0.20.1 - Unreleased
 
   INCOMPATIBLE CHANGES

Modified: hadoop/core/trunk/src/core/org/apache/hadoop/fs/s3native/NativeS3FileSystem.java
URL: http://svn.apache.org/viewvc/hadoop/core/trunk/src/core/org/apache/hadoop/fs/s3native/NativeS3FileSystem.java?rev=770681&r1=770680&r2=770681&view=diff
==============================================================================
--- hadoop/core/trunk/src/core/org/apache/hadoop/fs/s3native/NativeS3FileSystem.java (original)
+++ hadoop/core/trunk/src/core/org/apache/hadoop/fs/s3native/NativeS3FileSystem.java Fri May
 1 13:43:10 2009
@@ -90,6 +90,9 @@
       if (result != -1) {
         pos++;
       }
+      if (statistics != null && result != -1) {
+        statistics.incrementBytesRead(1);
+      }
       return result;
     }
     public synchronized int read(byte[] b, int off, int len)
@@ -99,6 +102,9 @@
       if (result > 0) {
         pos += result;
       }
+      if (statistics != null && result > 0) {
+        statistics.incrementBytesRead(result);
+      }
       return result;
     }
 



Mime
View raw message