hadoop-hdfs-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From hair...@apache.org
Subject svn commit: r807433 - in /hadoop/hdfs/trunk: CHANGES.txt src/java/org/apache/hadoop/hdfs/server/datanode/BlockSender.java
Date Tue, 25 Aug 2009 00:00:17 GMT
Author: hairong
Date: Tue Aug 25 00:00:17 2009
New Revision: 807433

URL: http://svn.apache.org/viewvc?rev=807433&view=rev
Log:
HDFS-553. BlockSender reports wrong failed position in ChecksumException. Contributed by Hairong
Kuang.

Modified:
    hadoop/hdfs/trunk/CHANGES.txt
    hadoop/hdfs/trunk/src/java/org/apache/hadoop/hdfs/server/datanode/BlockSender.java

Modified: hadoop/hdfs/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/hadoop/hdfs/trunk/CHANGES.txt?rev=807433&r1=807432&r2=807433&view=diff
==============================================================================
--- hadoop/hdfs/trunk/CHANGES.txt (original)
+++ hadoop/hdfs/trunk/CHANGES.txt Tue Aug 25 00:00:17 2009
@@ -173,6 +173,9 @@
     HDFS-561. Fix write pipeline READ_TIMEOUT in DataTransferProtocol.
     (Kan Zhang via szetszwo)
 
+    HDFS-553. BlockSender reports wrong failed position in ChecksumException.
+    (hairong)
+ 
 Release 0.20.1 - Unreleased
 
   IMPROVEMENTS

Modified: hadoop/hdfs/trunk/src/java/org/apache/hadoop/hdfs/server/datanode/BlockSender.java
URL: http://svn.apache.org/viewvc/hadoop/hdfs/trunk/src/java/org/apache/hadoop/hdfs/server/datanode/BlockSender.java?rev=807433&r1=807432&r2=807433&view=diff
==============================================================================
--- hadoop/hdfs/trunk/src/java/org/apache/hadoop/hdfs/server/datanode/BlockSender.java (original)
+++ hadoop/hdfs/trunk/src/java/org/apache/hadoop/hdfs/server/datanode/BlockSender.java Tue
Aug 25 00:00:17 2009
@@ -290,8 +290,9 @@
           int dLen = Math.min(dLeft, bytesPerChecksum);
           checksum.update(buf, dOff, dLen);
           if (!checksum.compare(buf, cOff)) {
+            long failedPos = offset + len -dLeft;
             throw new ChecksumException("Checksum failed at " + 
-                                        (offset + len - dLeft), len);
+                                        failedPos, failedPos);
           }
           dLeft -= dLen;
           dOff += dLen;



Mime
View raw message