hbase-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From st...@apache.org
Subject svn commit: r1483547 - /hbase/trunk/hbase-server/src/main/java/org/apache/hadoop/hbase/master/HMaster.java
Date Thu, 16 May 2013 20:28:19 GMT
Author: stack
Date: Thu May 16 20:28:19 2013
New Revision: 1483547

URL: http://svn.apache.org/r1483547
Log:
HBASE-8560 TestMasterShutdown failing in trunk 0.95/trunk -- "Unable to get data of znode
/hbase/meta-region-server because node does not exist (not an error)"

Modified:
    hbase/trunk/hbase-server/src/main/java/org/apache/hadoop/hbase/master/HMaster.java

Modified: hbase/trunk/hbase-server/src/main/java/org/apache/hadoop/hbase/master/HMaster.java
URL: http://svn.apache.org/viewvc/hbase/trunk/hbase-server/src/main/java/org/apache/hadoop/hbase/master/HMaster.java?rev=1483547&r1=1483546&r2=1483547&view=diff
==============================================================================
--- hbase/trunk/hbase-server/src/main/java/org/apache/hadoop/hbase/master/HMaster.java (original)
+++ hbase/trunk/hbase-server/src/main/java/org/apache/hadoop/hbase/master/HMaster.java Thu
May 16 20:28:19 2013
@@ -801,6 +801,9 @@ MasterServices, Server {
     // Make sure meta assigned before proceeding.
     status.setStatus("Assigning Meta Region");
     assignMeta(status);
+    // check if master is shutting down because above assignMeta could return even META isn't

+    // assigned when master is shutting down
+    if(this.stopped) return;
 
     if (this.distributedLogReplay && oldMetaServerLocation != null
         && previouslyFailedServers.contains(oldMetaServerLocation)) {
@@ -941,6 +944,7 @@ MasterServices, Server {
       this.assignmentManager.regionOnline(HRegionInfo.FIRST_META_REGIONINFO,
         this.catalogTracker.getMetaLocation());
     }
+
     enableCatalogTables(Bytes.toString(HConstants.META_TABLE_NAME));
     LOG.info(".META. assigned=" + assigned + ", rit=" + rit + ", location="
         + catalogTracker.getMetaLocation());
@@ -2059,7 +2063,7 @@ MasterServices, Server {
           serverShutdownHandlerEnabled = false;
           initialized = false;
           finishInitialization(status, true);
-          return Boolean.TRUE;
+          return !stopped;
         } finally {
           status.cleanup();
         }



Mime
View raw message