diff --git a/hbase-server/src/main/java/org/apache/hadoop/hbase/master/MetricsMasterWrapperImpl.java b/hbase-server/src/main/java/org/apache/hadoop/hbase/master/MetricsMasterWrapperImpl.java index e03c4df3aa3..d65b0291366 100644 --- a/hbase-server/src/main/java/org/apache/hadoop/hbase/master/MetricsMasterWrapperImpl.java +++ b/hbase-server/src/main/java/org/apache/hadoop/hbase/master/MetricsMasterWrapperImpl.java @@ -55,11 +55,17 @@ public class MetricsMasterWrapperImpl implements MetricsMasterWrapper { @Override public long getSplitPlanCount() { + if (master.getRegionNormalizerManager() == null) { + return 0; + } return master.getRegionNormalizerManager().getSplitPlanCount(); } @Override public long getMergePlanCount() { + if (master.getRegionNormalizerManager() == null) { + return 0; + } return master.getRegionNormalizerManager().getMergePlanCount(); }