You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hbase.apache.org by wc...@apache.org on 2021/10/28 08:51:10 UTC

[hbase] branch branch-2.4 updated: HBASE-26398 CellCounter fails for large tables filling up local disk (#3798)

This is an automated email from the ASF dual-hosted git repository.

wchevreuil pushed a commit to branch branch-2.4
in repository https://gitbox.apache.org/repos/asf/hbase.git


The following commit(s) were added to refs/heads/branch-2.4 by this push:
     new 5fbb089  HBASE-26398 CellCounter fails for large tables filling up local disk (#3798)
5fbb089 is described below

commit 5fbb089c9257d1809bf6477236cc3c32f9b9acab
Author: Istvan Toth <st...@apache.org>
AuthorDate: Thu Oct 28 10:42:42 2021 +0200

    HBASE-26398 CellCounter fails for large tables filling up local disk (#3798)
    
    Signed-off-by: Wellington Chevreuil <wc...@apache.org>
    (cherry picked from commit 60254bc18476195d60669ee4a357aee7d68797c9)
---
 .../src/main/java/org/apache/hadoop/hbase/mapreduce/CellCounter.java    | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/hbase-mapreduce/src/main/java/org/apache/hadoop/hbase/mapreduce/CellCounter.java b/hbase-mapreduce/src/main/java/org/apache/hadoop/hbase/mapreduce/CellCounter.java
index cc3d554..d338680 100644
--- a/hbase-mapreduce/src/main/java/org/apache/hadoop/hbase/mapreduce/CellCounter.java
+++ b/hbase-mapreduce/src/main/java/org/apache/hadoop/hbase/mapreduce/CellCounter.java
@@ -215,7 +215,6 @@ public class CellCounter extends Configured implements Tool {
     Scan scan = getConfiguredScanForJob(conf, args);
     TableMapReduceUtil.initTableMapperJob(tableName, scan,
         CellCounterMapper.class, ImmutableBytesWritable.class, Result.class, job);
-    job.setNumReduceTasks(1);
     job.setMapOutputKeyClass(Text.class);
     job.setMapOutputValueClass(IntWritable.class);
     job.setOutputFormatClass(TextOutputFormat.class);
@@ -223,6 +222,7 @@ public class CellCounter extends Configured implements Tool {
     job.setOutputValueClass(IntWritable.class);
     FileOutputFormat.setOutputPath(job, outputDir);
     job.setReducerClass(IntSumReducer.class);
+    job.setCombinerClass(IntSumReducer.class);
     return job;
   }