diff --git a/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/compactions/Compactor.java b/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/compactions/Compactor.java index 660ea9134aa..3728c7c5196 100644 --- a/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/compactions/Compactor.java +++ b/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/compactions/Compactor.java @@ -335,7 +335,7 @@ public abstract class Compactor { int minFilesToCompact = Math.max(2, conf.getInt(CompactionConfiguration.HBASE_HSTORE_COMPACTION_MIN_KEY, /* old name */ conf.getInt("hbase.hstore.compactionThreshold", 3))); - long shippedCallSizeLimit = minFilesToCompact * HConstants.DEFAULT_BLOCKSIZE; + long shippedCallSizeLimit = (long) minFilesToCompact * HConstants.DEFAULT_BLOCKSIZE; try { do { hasMore = scanner.next(cells, scannerContext); diff --git a/hbase-server/src/main/java/org/apache/hadoop/hbase/snapshot/ExportSnapshot.java b/hbase-server/src/main/java/org/apache/hadoop/hbase/snapshot/ExportSnapshot.java index a574410ebea..c0b2ce8e7f8 100644 --- a/hbase-server/src/main/java/org/apache/hadoop/hbase/snapshot/ExportSnapshot.java +++ b/hbase-server/src/main/java/org/apache/hadoop/hbase/snapshot/ExportSnapshot.java @@ -270,7 +270,7 @@ public class ExportSnapshot extends Configured implements Tool { InputStream in = openSourceFile(context, inputInfo); int bandwidthMB = context.getConfiguration().getInt(CONF_BANDWIDTH_MB, 100); if (Integer.MAX_VALUE != bandwidthMB) { - in = new ThrottledInputStream(new BufferedInputStream(in), bandwidthMB * 1024 * 1024); + in = new ThrottledInputStream(new BufferedInputStream(in), bandwidthMB * 1024 * 1024L); } try {