meatballspaghetti commented on code in PR #5350:
URL: https://github.com/apache/accumulo/pull/5350#discussion_r1998886303


##########
server/base/src/main/java/org/apache/accumulo/server/conf/store/impl/ZooPropStore.java:
##########
@@ -85,33 +83,28 @@ public class ZooPropStore implements PropStore, 
PropChangeListener {
     } else {
       this.cache = new 
PropCacheCaffeineImpl.Builder(propLoader).forTests(ticker).build();
     }
-
     try {
-      var path = ZooUtil.getRoot(instanceId);
-      if (zrw.exists(path, propStoreWatcher)) {
-        log.debug("Have a ZooKeeper connection and found instance node: {}", 
instanceId);
+      if (zrw.exists("/", propStoreWatcher)) {
+        log.debug("Have a ZooKeeper connection and found instance node: {}");
         zkReadyMon.setReady();
       } else {
-        throw new IllegalStateException("Instance may not have been 
initialized, root node: " + path
-            + " does not exist in ZooKeeper");
+        throw new IllegalStateException(
+            "Instance may not have been initialized, provided root node path 
does not exist in ZooKeeper");
       }
     } catch (InterruptedException ex) {
       Thread.currentThread().interrupt();
-      throw new IllegalStateException(
-          "Interrupted trying to read root node " + instanceId + " from 
ZooKeeper", ex);
+      throw new IllegalStateException("Interrupted trying to read root node 
from ZooKeeper", ex);

Review Comment:
   Fixed to specify that what is being failed to be read is the instance root 
node at `/accumulo/<uuid>`.



##########
server/base/src/main/java/org/apache/accumulo/server/conf/store/impl/ZooPropStore.java:
##########
@@ -85,33 +83,28 @@ public class ZooPropStore implements PropStore, 
PropChangeListener {
     } else {
       this.cache = new 
PropCacheCaffeineImpl.Builder(propLoader).forTests(ticker).build();
     }
-
     try {
-      var path = ZooUtil.getRoot(instanceId);
-      if (zrw.exists(path, propStoreWatcher)) {
-        log.debug("Have a ZooKeeper connection and found instance node: {}", 
instanceId);
+      if (zrw.exists("/", propStoreWatcher)) {
+        log.debug("Have a ZooKeeper connection and found instance node: {}");
         zkReadyMon.setReady();
       } else {
-        throw new IllegalStateException("Instance may not have been 
initialized, root node: " + path
-            + " does not exist in ZooKeeper");
+        throw new IllegalStateException(
+            "Instance may not have been initialized, provided root node path 
does not exist in ZooKeeper");
       }
     } catch (InterruptedException ex) {
       Thread.currentThread().interrupt();
-      throw new IllegalStateException(
-          "Interrupted trying to read root node " + instanceId + " from 
ZooKeeper", ex);
+      throw new IllegalStateException("Interrupted trying to read root node 
from ZooKeeper", ex);
     } catch (KeeperException ex) {
-      throw new IllegalStateException("Failed to read root node " + instanceId 
+ " from ZooKeeper",
-          ex);
+      throw new IllegalStateException("Failed to read root node from 
ZooKeeper", ex);

Review Comment:
   Fixed to specify that what is being failed to be read is the instance root 
node at `/accumulo/<uuid>`.



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