You are viewing a plain text version of this content. The canonical link for it is here.
Posted to common-commits@hadoop.apache.org by to...@apache.org on 2011/03/07 04:16:27 UTC

svn commit: r1078660 - in /hadoop/common/trunk: CHANGES.txt src/java/org/apache/hadoop/io/Text.java

Author: todd
Date: Mon Mar  7 03:16:27 2011
New Revision: 1078660

URL: http://svn.apache.org/viewvc?rev=1078660&view=rev
Log:
HADOOP-7131. Exceptions thrown by Text methods should include the causing exception. Contributed by Uma Maheswara Rao G.

Modified:
    hadoop/common/trunk/CHANGES.txt
    hadoop/common/trunk/src/java/org/apache/hadoop/io/Text.java

Modified: hadoop/common/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/CHANGES.txt?rev=1078660&r1=1078659&r2=1078660&view=diff
==============================================================================
--- hadoop/common/trunk/CHANGES.txt (original)
+++ hadoop/common/trunk/CHANGES.txt Mon Mar  7 03:16:27 2011
@@ -94,6 +94,9 @@ Trunk (unreleased changes)
     HADOOP-7098. Tasktracker property not set in conf/hadoop-env.sh.
     (Bernd Fondermann via tomwhite)
 
+    HADOOP-7131. Exceptions thrown by Text methods should include the causing
+    exception. (Uma Maheswara Rao G via todd)
+
 Release 0.22.0 - Unreleased
 
   INCOMPATIBLE CHANGES

Modified: hadoop/common/trunk/src/java/org/apache/hadoop/io/Text.java
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/src/java/org/apache/hadoop/io/Text.java?rev=1078660&r1=1078659&r2=1078660&view=diff
==============================================================================
--- hadoop/common/trunk/src/java/org/apache/hadoop/io/Text.java (original)
+++ hadoop/common/trunk/src/java/org/apache/hadoop/io/Text.java Mon Mar  7 03:16:27 2011
@@ -195,7 +195,7 @@ public class Text extends BinaryComparab
       bytes = bb.array();
       length = bb.limit();
     }catch(CharacterCodingException e) {
-      throw new RuntimeException("Should not have happened " + e.toString()); 
+      throw new RuntimeException("Should not have happened ", e); 
     }
   }
 
@@ -269,7 +269,7 @@ public class Text extends BinaryComparab
     try {
       return decode(bytes, 0, length);
     } catch (CharacterCodingException e) { 
-      throw new RuntimeException("Should not have happened " + e.toString()); 
+      throw new RuntimeException("Should not have happened " , e); 
     }
   }