hadoop-common-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From cdoug...@apache.org
Subject svn commit: r669327 - in /hadoop/core/trunk: CHANGES.txt src/contrib/data_join/src/java/org/apache/hadoop/contrib/utils/join/DataJoinReducerBase.java
Date Wed, 18 Jun 2008 22:51:03 GMT
Author: cdouglas
Date: Wed Jun 18 15:51:02 2008
New Revision: 669327

URL: http://svn.apache.org/viewvc?rev=669327&view=rev
Log:
HADOOP-3526. Fix contrib/data_join framework by cloning values retained in the
reduce. Contributed by Spyros Blanas.


Modified:
    hadoop/core/trunk/CHANGES.txt
    hadoop/core/trunk/src/contrib/data_join/src/java/org/apache/hadoop/contrib/utils/join/DataJoinReducerBase.java

Modified: hadoop/core/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/hadoop/core/trunk/CHANGES.txt?rev=669327&r1=669326&r2=669327&view=diff
==============================================================================
--- hadoop/core/trunk/CHANGES.txt (original)
+++ hadoop/core/trunk/CHANGES.txt Wed Jun 18 15:51:02 2008
@@ -628,6 +628,9 @@
     HADOOP-3550. Fix the serialization data structures in MapTask where the
     value lengths are incorrectly calculated. (cdouglas)
 
+    HADOOP-3526. Fix contrib/data_join framework by cloning values retained
+    in the reduce. (Spyros Blanas via cdouglas)
+
 Release 0.17.1 - Unreleased
 
   INCOMPATIBLE CHANGES

Modified: hadoop/core/trunk/src/contrib/data_join/src/java/org/apache/hadoop/contrib/utils/join/DataJoinReducerBase.java
URL: http://svn.apache.org/viewvc/hadoop/core/trunk/src/contrib/data_join/src/java/org/apache/hadoop/contrib/utils/join/DataJoinReducerBase.java?rev=669327&r1=669326&r2=669327&view=diff
==============================================================================
--- hadoop/core/trunk/src/contrib/data_join/src/java/org/apache/hadoop/contrib/utils/join/DataJoinReducerBase.java
(original)
+++ hadoop/core/trunk/src/contrib/data_join/src/java/org/apache/hadoop/contrib/utils/join/DataJoinReducerBase.java
Wed Jun 18 15:51:02 2008
@@ -24,6 +24,7 @@
 import java.util.TreeMap;
 
 import org.apache.hadoop.io.Text;
+import org.apache.hadoop.io.WritableUtils;
 import org.apache.hadoop.mapred.JobConf;
 import org.apache.hadoop.mapred.OutputCollector;
 import org.apache.hadoop.mapred.Reporter;
@@ -103,13 +104,13 @@
       if (this.numOfValues > this.maxNumOfValuesPerGroup) {
         continue;
       }
-      Object tag = aRecord.getTag();
+      Text tag = new Text((Text)aRecord.getTag());
       ResetableIterator data = retv.get(tag);
       if (data == null) {
         data = createResetableIterator();
         retv.put(tag, data);
       }
-      data.add(aRecord);
+      data.add(WritableUtils.clone(aRecord, job));
     }
     if (this.numOfValues > this.largestNumOfValues) {
       this.largestNumOfValues = numOfValues;



Mime
View raw message