hbase-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From st...@apache.org
Subject [45/50] [abbrv] hbase git commit: Fix NPE in CJ
Date Tue, 23 May 2017 07:36:57 GMT
Fix NPE in CJ


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

Branch: refs/heads/HBASE-14614
Commit: 0a216deefea1ee2f8792c50833d77b789feb4284
Parents: 7b5e5cd
Author: Michael Stack <stack@apache.org>
Authored: Wed May 17 09:43:07 2017 -0700
Committer: Michael Stack <stack@apache.org>
Committed: Tue May 23 00:33:03 2017 -0700

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


http://git-wip-us.apache.org/repos/asf/hbase/blob/0a216dee/hbase-server/src/main/java/org/apache/hadoop/hbase/master/CatalogJanitor.java
----------------------------------------------------------------------
diff --git a/hbase-server/src/main/java/org/apache/hadoop/hbase/master/CatalogJanitor.java
b/hbase-server/src/main/java/org/apache/hadoop/hbase/master/CatalogJanitor.java
index 7d43f2f..dc0c0a6 100644
--- a/hbase-server/src/main/java/org/apache/hadoop/hbase/master/CatalogJanitor.java
+++ b/hbase-server/src/main/java/org/apache/hadoop/hbase/master/CatalogJanitor.java
@@ -346,9 +346,12 @@ public class CatalogJanitor extends ScheduledChore {
     Pair<Boolean, Boolean> a = checkDaughterInFs(parent, daughters.getFirst());
     Pair<Boolean, Boolean> b = checkDaughterInFs(parent, daughters.getSecond());
     if (hasNoReferences(a) && hasNoReferences(b)) {
+      String daughterA = daughters.getFirst() != null?
+          daughters.getFirst().getShortNameToLog(): "null";
+      String daughterB = daughters.getSecond() != null?
+          daughters.getSecond().getShortNameToLog(): "null";
       LOG.debug("Deleting region " + parent.getShortNameToLog() +
-        " because daughters -- " + daughters.getFirst().getShortNameToLog() + ", " +
-          daughters.getSecond().getShortNameToLog() +
+        " because daughters -- " + daughterA + ", " + daughterB +
         " -- no longer hold references");
       ProcedureExecutor<MasterProcedureEnv> pe = this.services.getMasterProcedureExecutor();
       pe.submitProcedure(new GCRegionProcedure(pe.getEnvironment(), parent));


Mime
View raw message