hbase-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From te...@apache.org
Subject hbase git commit: HBASE-14885 NullPointerException in HMaster#normalizeRegions() due to missing TableDescriptor
Date Thu, 26 Nov 2015 00:06:50 GMT
Repository: hbase
Updated Branches:
  refs/heads/master efb5917f2 -> e73a9594c


HBASE-14885 NullPointerException in HMaster#normalizeRegions() due to missing TableDescriptor


Project: http://git-wip-us.apache.org/repos/asf/hbase/repo
Commit: http://git-wip-us.apache.org/repos/asf/hbase/commit/e73a9594
Tree: http://git-wip-us.apache.org/repos/asf/hbase/tree/e73a9594
Diff: http://git-wip-us.apache.org/repos/asf/hbase/diff/e73a9594

Branch: refs/heads/master
Commit: e73a9594c218ed969a2f5b0b356d7b8d0e1474c0
Parents: efb5917
Author: tedyu <yuzhihong@gmail.com>
Authored: Wed Nov 25 16:06:27 2015 -0800
Committer: tedyu <yuzhihong@gmail.com>
Committed: Wed Nov 25 16:06:27 2015 -0800

----------------------------------------------------------------------
 .../src/main/java/org/apache/hadoop/hbase/master/HMaster.java | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/hbase/blob/e73a9594/hbase-server/src/main/java/org/apache/hadoop/hbase/master/HMaster.java
----------------------------------------------------------------------
diff --git a/hbase-server/src/main/java/org/apache/hadoop/hbase/master/HMaster.java b/hbase-server/src/main/java/org/apache/hadoop/hbase/master/HMaster.java
index b30de7c..46c7f79 100644
--- a/hbase-server/src/main/java/org/apache/hadoop/hbase/master/HMaster.java
+++ b/hbase-server/src/main/java/org/apache/hadoop/hbase/master/HMaster.java
@@ -69,6 +69,7 @@ import org.apache.hadoop.hbase.ProcedureInfo;
 import org.apache.hadoop.hbase.Server;
 import org.apache.hadoop.hbase.ServerLoad;
 import org.apache.hadoop.hbase.ServerName;
+import org.apache.hadoop.hbase.TableDescriptor;
 import org.apache.hadoop.hbase.TableDescriptors;
 import org.apache.hadoop.hbase.TableName;
 import org.apache.hadoop.hbase.TableNotDisabledException;
@@ -1357,8 +1358,10 @@ public class HMaster extends HRegionServer implements MasterServices,
Server {
           LOG.debug("Skipping normalizing " + table + " since its namespace has quota");
           continue;
         }
-        if (table.isSystemTable() || !getTableDescriptors().getDescriptor(table).
-            getHTableDescriptor().isNormalizationEnabled()) {
+        TableDescriptor tblDesc = getTableDescriptors().getDescriptor(table);
+        if (table.isSystemTable() || (tblDesc != null &&
+            tblDesc.getHTableDescriptor() != null &&
+            !tblDesc.getHTableDescriptor().isNormalizationEnabled())) {
           LOG.debug("Skipping normalization for table: " + table + ", as it's either system"
             + " table or doesn't have auto normalization turned on");
           continue;


Mime
View raw message