chandrasekhar-188k commented on code in PR #5841:
URL: https://github.com/apache/hbase/pull/5841#discussion_r1580639524


##########
hbase-server/src/main/java/org/apache/hadoop/hbase/master/procedure/InitMetaProcedure.java:
##########
@@ -119,6 +122,19 @@ protected Flow executeFromState(MasterProcedureEnv env, 
InitMetaState state)
           // namespaces when starting.
           insertNamespaceToMeta(env.getMasterServices().getConnection(), 
DEFAULT_NAMESPACE);
           insertNamespaceToMeta(env.getMasterServices().getConnection(), 
SYSTEM_NAMESPACE);
+          // create the additional namespaces based on the configuration value
+          String[] customNamespaces =
+            env.getMasterConfiguration().getStrings(ADDITIONAL_NAMESPACES);
+          if (null != customNamespaces && customNamespaces.length > 0) {
+            Arrays.stream(customNamespaces).forEach(ns -> {

Review Comment:
   This improvement provides a config option for operators to create the 
additional namespaces during the HBase startup. This would eliminate the need 
to wrap createTable calls in checkAndCreateNamespace or provide separate 
cluster bootstrap functionality to guarantee that the namespace is created.



-- 
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.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to