anoopsjohn commented on a change in pull request #2237:
URL: https://github.com/apache/hbase/pull/2237#discussion_r469412600



##########
File path: 
hbase-server/src/main/java/org/apache/hadoop/hbase/master/HMaster.java
##########
@@ -915,6 +917,11 @@ private void 
finishActiveMasterInitialization(MonitoredTask status)
       this.tableDescriptors.getAll();
     }
 
+    // check cluster Id stored in ZNode before, and use it to indicate if a 
cluster has been
+    // restarted with an existing Zookeeper quorum.
+    isClusterRestartWithExistingZNodes =

Review comment:
       Ya at proc level..  But before that itself one more thing.
   Say there is a cluster recreate over existing data and so no zk node for 
clusterId. We will get true for 'isClusterRestartWithExistingZNodes '. In next 
lines, we will create and write the zk node for clusterId.  Now assume after 
executing that lines, the HM restarted.  So the zk node was created but the 
InitMetaProc was NOT submitted.  Now after restart, when we come here, we have 
zk data for clusterId.  So 'isClusterRestartWithExistingZNodes ' will become 
false.  Now this time the InitMetaProc started and as part of that we will end 
up deleting the Meta dir.
   So this says the need to keep this boolean info somewhere once we find that 
and even before creating the zk node for ClusterId.  Am I making the concern 
clear this time?




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Reply via email to