diff --git ql/src/java/org/apache/hadoop/hive/ql/exec/tez/ReduceRecordProcessor.java ql/src/java/org/apache/hadoop/hive/ql/exec/tez/ReduceRecordProcessor.java index 990a4f1..c4a38d8 100644 --- ql/src/java/org/apache/hadoop/hive/ql/exec/tez/ReduceRecordProcessor.java +++ ql/src/java/org/apache/hadoop/hive/ql/exec/tez/ReduceRecordProcessor.java @@ -437,6 +437,7 @@ private boolean processKeyValues(Iterable values, byte tag) throws HiveE private boolean processVectors(Iterable values, byte tag) throws HiveException { VectorizedRowBatch batch = batches[tag]; batch.reset(); + buffer.reset(); /* deserialize key into columns */ VectorizedBatchUtil.addRowToBatchFrom(keyObject, keyStructInspector, @@ -459,6 +460,7 @@ private boolean processVectors(Iterable values, byte tag) throws HiveExc VectorizedBatchUtil.setBatchSize(batch, rowIdx); reducer.processOp(batch, tag); rowIdx = 0; + buffer.reset(); if (isLogInfoEnabled) { logProgress(); } @@ -467,6 +469,7 @@ private boolean processVectors(Iterable values, byte tag) throws HiveExc if (rowIdx > 0) { VectorizedBatchUtil.setBatchSize(batch, rowIdx); reducer.processOp(batch, tag); + buffer.reset(); } if (isLogInfoEnabled) { logProgress();