HBASE-16059 Region normalizer fails to trigger merge action where one of the regions is empty
This commit is contained in:
parent
095a82584e
commit
be56b5ae71
|
@ -182,7 +182,7 @@ public class SimpleRegionNormalizer implements RegionNormalizer {
|
||||||
if (mergeEnabled) {
|
if (mergeEnabled) {
|
||||||
HRegionInfo hri2 = tableRegions.get(candidateIdx+1);
|
HRegionInfo hri2 = tableRegions.get(candidateIdx+1);
|
||||||
long regionSize2 = getRegionSize(hri2);
|
long regionSize2 = getRegionSize(hri2);
|
||||||
if (regionSize > 0 && regionSize2 > 0 && regionSize + regionSize2 < avgRegionSize) {
|
if (regionSize >= 0 && regionSize2 >= 0 && regionSize + regionSize2 < avgRegionSize) {
|
||||||
LOG.info("Table " + table + ", small region size: " + regionSize
|
LOG.info("Table " + table + ", small region size: " + regionSize
|
||||||
+ " plus its neighbor size: " + regionSize2
|
+ " plus its neighbor size: " + regionSize2
|
||||||
+ ", less than the avg size " + avgRegionSize + ", merging them");
|
+ ", less than the avg size " + avgRegionSize + ", merging them");
|
||||||
|
|
Loading…
Reference in New Issue