HoustonPutman commented on code in PR #760:
URL: https://github.com/apache/solr/pull/760#discussion_r1356982674


##########
solr/solrj-zookeeper/src/java/org/apache/solr/common/cloud/SolrZkClient.java:
##########
@@ -138,82 +143,82 @@ private SolrZkClient(
       return;
     }
     this.zkServerAddress = zkServerAddress;
-    this.higherLevelIsClosed = higherLevelIsClosed;
-    if (strat == null) {
-      String connectionStrategy = 
System.getProperty("solr.zookeeper.connectionStrategy");
-      strat =
-          ZkClientConnectionStrategy.forName(connectionStrategy, new 
DefaultConnectionStrategy());
+    String chroot, zkHost;
+    int chrootIndex = zkServerAddress.indexOf('/');
+    if (chrootIndex == -1) {
+      zkHost = zkServerAddress;
+      chroot = null;
+    } else if (chrootIndex == zkServerAddress.length() - 1) {
+      zkHost = zkServerAddress.substring(0, zkServerAddress.length() - 1);
+      chroot = null;
+    } else {
+      zkHost = zkServerAddress.substring(0, chrootIndex);
+      chroot = zkServerAddress.substring(chrootIndex + 1);
     }
-    this.zkClientConnectionStrategy = strat;
 
-    this.solrClassLoader = solrClassLoader;

Review Comment:
   I don't think we wanted to remove this line.



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