HBASE-17912 - Avoid major compactions on region server startup

Signed-off-by: tedyu <yuzhihong@gmail.com>
This commit is contained in:
gjacoby 2017-04-17 16:08:25 -07:00 committed by tedyu
parent 3c32032f5c
commit 5eda5fb9d7
1 changed files with 3 additions and 1 deletions

View File

@ -1628,7 +1628,9 @@ public class HRegionServer extends HasThread implements
private final HRegionServer instance; private final HRegionServer instance;
private final int majorCompactPriority; private final int majorCompactPriority;
private final static int DEFAULT_PRIORITY = Integer.MAX_VALUE; private final static int DEFAULT_PRIORITY = Integer.MAX_VALUE;
private long iteration = 0; //Iteration is 1-based rather than 0-based so we don't check for compaction
// immediately upon region server startup
private long iteration = 1;
CompactionChecker(final HRegionServer h, final int sleepTime, CompactionChecker(final HRegionServer h, final int sleepTime,
final Stoppable stopper) { final Stoppable stopper) {