maedhroz commented on code in PR #3474:
URL: https://github.com/apache/cassandra/pull/3474#discussion_r1722357973


##########
src/java/org/apache/cassandra/config/DatabaseDescriptor.java:
##########
@@ -271,6 +274,42 @@ public static void daemonInitialization(Supplier<Config> 
config) throws Configur
         AuthConfig.applyAuth();
     }
 
+    public static void unsafeDaemonInitialization(Supplier<Config> config) 
throws ConfigurationException
+    {
+        if (toolInitialized)
+            throw new AssertionError("toolInitialization() already called");
+        if (clientInitialized)
+            throw new AssertionError("clientInitialization() already called");

Review Comment:
   nit: We could de-dup the 3 places where these are called w/ something like...
   
   ```
   assertNotToolInitialized();
   assertNotClientInitialized();
   ```
   
   Not much ROI, but up to you.



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


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to