Apache Solr open-source search software
SOLR-15409: Upgrade to Zookeeper 3.7.0 (#130)
Mike Drob6d3e512a2817
diff --git a/solr/CHANGES.txt b/solr/CHANGES.txtindex 2a540bd930b..9278291d2b6 100644--- a/solr/CHANGES.txt+++ b/solr/CHANGES.txt@@ -293,6 +293,8 @@ Other Changes* SOLR-15222: userfiles dir will only be created in SolrCloud mode (Mike Drob)+* SOLR-15409: Upgrade to Zookeeper 3.7.0 (Mike Drob)+Bug Fixes---------------------* SOLR-14546: Fix for a relatively hard to hit issue in OverseerTaskProcessor that could lead to out of order executiondiff --git a/solr/licenses/commons-lang-2.6.jar.sha1 b/solr/licenses/commons-lang-2.6.jar.sha1deleted file mode 100644index 4d7b0bf1d9d..00000000000--- a/solr/licenses/commons-lang-2.6.jar.sha1+++ /dev/null@@ -1 +0,0 @@-0ce1edb914c94ebc388f086c6827e8bdeec71ac2diff --git a/solr/licenses/netty-buffer-4.1.50.Final.jar.sha1 b/solr/licenses/netty-buffer-4.1.50.Final.jar.sha1deleted file mode 100644index 8e8923e0e24..00000000000--- a/solr/licenses/netty-buffer-4.1.50.Final.jar.sha1+++ /dev/null@@ -1 +0,0 @@-42b556977c572a376172a3270537ee22203c1a35diff --git a/solr/licenses/netty-buffer-4.1.59.Final.jar.sha1 b/solr/licenses/netty-buffer-4.1.59.Final.jar.sha1new file mode 100644index 00000000000..272f1f9b648--- /dev/null+++ b/solr/licenses/netty-buffer-4.1.59.Final.jar.sha1@@ -0,0 +1 @@+a1f281008d7e9574c14d386b39b3639a240eb0d1diff --git a/solr/licenses/netty-codec-4.1.50.Final.jar.sha1 b/solr/licenses/netty-codec-4.1.50.Final.jar.sha1deleted file mode 100644index 791103107b9..00000000000--- a/solr/licenses/netty-codec-4.1.50.Final.jar.sha1+++ /dev/null@@ -1 +0,0 @@-cbcb646c9380c6cdc3f56603ae6418a11418ce0fdiff --git a/solr/licenses/netty-codec-4.1.59.Final.jar.sha1 b/solr/licenses/netty-codec-4.1.59.Final.jar.sha1new file mode 100644index 00000000000..e2721d70316--- /dev/null+++ b/solr/licenses/netty-codec-4.1.59.Final.jar.sha1@@ -0,0 +1 @@+5e563309b99cf55bdbecc4dab7c417a0167c31aadiff --git a/solr/licenses/netty-common-4.1.50.Final.jar.sha1 b/solr/licenses/netty-common-4.1.50.Final.jar.sha1deleted file mode 100644index 3f9682dabeb..00000000000--- a/solr/licenses/netty-common-4.1.50.Final.jar.sha1+++ /dev/null@@ -1 +0,0 @@-d2059030b86733c52fd999e63db7300414b487fadiff --git a/solr/licenses/netty-common-4.1.59.Final.jar.sha1 b/solr/licenses/netty-common-4.1.59.Final.jar.sha1new file mode 100644index 00000000000..05b050907b7--- /dev/null+++ b/solr/licenses/netty-common-4.1.59.Final.jar.sha1@@ -0,0 +1 @@+e8800b0c50b6743ec1c5a3713816ce58910a703adiff --git a/solr/licenses/netty-handler-4.1.50.Final.jar.sha1 b/solr/licenses/netty-handler-4.1.50.Final.jar.sha1deleted file mode 100644index 8e80024a1d6..00000000000--- a/solr/licenses/netty-handler-4.1.50.Final.jar.sha1+++ /dev/null@@ -1 +0,0 @@-dc0110fc4d22fb22f1038cd73a6f8a034928a2d7diff --git a/solr/licenses/netty-handler-4.1.59.Final.jar.sha1 b/solr/licenses/netty-handler-4.1.59.Final.jar.sha1new file mode 100644index 00000000000..7369bef39b1--- /dev/null+++ b/solr/licenses/netty-handler-4.1.59.Final.jar.sha1@@ -0,0 +1 @@+302b4c8ca800aeddcf94401f2403114c8f5db5a5diff --git a/solr/licenses/netty-resolver-4.1.50.Final.jar.sha1 b/solr/licenses/netty-resolver-4.1.50.Final.jar.sha1deleted file mode 100644index 114714bf69f..00000000000--- a/solr/licenses/netty-resolver-4.1.50.Final.jar.sha1+++ /dev/null@@ -1 +0,0 @@-deb87b3c901142d73279a58e16867cf6f2b1c2e5diff --git a/solr/licenses/netty-resolver-4.1.59.Final.jar.sha1 b/solr/licenses/netty-resolver-4.1.59.Final.jar.sha1new file mode 100644index 00000000000..6a537efebf6--- /dev/null+++ b/solr/licenses/netty-resolver-4.1.59.Final.jar.sha1@@ -0,0 +1 @@+26bc136952a9f7a994dd7162f481c860275948dediff --git a/solr/licenses/netty-transport-4.1.50.Final.jar.sha1 b/solr/licenses/netty-transport-4.1.50.Final.jar.sha1deleted file mode 100644index aab40bea41d..00000000000--- a/solr/licenses/netty-transport-4.1.50.Final.jar.sha1+++ /dev/null@@ -1 +0,0 @@-2e4f6b655933faca0deef8d234ac6725b598109adiff --git a/solr/licenses/netty-transport-4.1.59.Final.jar.sha1 b/solr/licenses/netty-transport-4.1.59.Final.jar.sha1new file mode 100644index 00000000000..c8099d0a7a3--- /dev/null+++ b/solr/licenses/netty-transport-4.1.59.Final.jar.sha1@@ -0,0 +1 @@+864d20f35ce909e6a7462095cb8f91ee94d1cd4cdiff --git a/solr/licenses/netty-transport-native-epoll-4.1.50.Final.jar.sha1 b/solr/licenses/netty-transport-native-epoll-4.1.50.Final.jar.sha1deleted file mode 100644index 2d841801ede..00000000000--- a/solr/licenses/netty-transport-native-epoll-4.1.50.Final.jar.sha1+++ /dev/null@@ -1 +0,0 @@-480ab17c1ebfb32fcd493577d3e3241dc56e62f4diff --git a/solr/licenses/netty-transport-native-epoll-4.1.59.Final.jar.sha1 b/solr/licenses/netty-transport-native-epoll-4.1.59.Final.jar.sha1new file mode 100644index 00000000000..45ea4ea12dc--- /dev/null+++ b/solr/licenses/netty-transport-native-epoll-4.1.59.Final.jar.sha1@@ -0,0 +1 @@+0d80613566ff6aa65580325d4a8ec6126b6cd47adiff --git a/solr/licenses/netty-transport-native-unix-common-4.1.50.Final.jar.sha1 b/solr/licenses/netty-transport-native-unix-common-4.1.50.Final.jar.sha1deleted file mode 100644index 63b68ff929e..00000000000--- a/solr/licenses/netty-transport-native-unix-common-4.1.50.Final.jar.sha1+++ /dev/null@@ -1 +0,0 @@-87b98225422fccf2bf113e169c45e683de200a3ediff --git a/solr/licenses/netty-transport-native-unix-common-4.1.59.Final.jar.sha1 b/solr/licenses/netty-transport-native-unix-common-4.1.59.Final.jar.sha1new file mode 100644index 00000000000..ccc1b7450a4--- /dev/null+++ b/solr/licenses/netty-transport-native-unix-common-4.1.59.Final.jar.sha1@@ -0,0 +1 @@+f5d4ad1f995ec40c20220ad9ec75b14172ac9320diff --git a/solr/licenses/zookeeper-3.6.2.jar.sha1 b/solr/licenses/zookeeper-3.6.2.jar.sha1deleted file mode 100644index c2ebcdab8e8..00000000000--- a/solr/licenses/zookeeper-3.6.2.jar.sha1+++ /dev/null@@ -1 +0,0 @@-bd0630f2de482ce8a14bc1de8dc12ef6197f4624diff --git a/solr/licenses/zookeeper-3.7.0.jar.sha1 b/solr/licenses/zookeeper-3.7.0.jar.sha1new file mode 100644index 00000000000..eaac8f2b7f8--- /dev/null+++ b/solr/licenses/zookeeper-3.7.0.jar.sha1@@ -0,0 +1 @@+1360048c7ca057df627b7267ff7360870e987ab0diff --git a/solr/licenses/zookeeper-jute-3.6.2.jar.sha1 b/solr/licenses/zookeeper-jute-3.6.2.jar.sha1deleted file mode 100644index 05a9ea45c69..00000000000--- a/solr/licenses/zookeeper-jute-3.6.2.jar.sha1+++ /dev/null@@ -1 +0,0 @@-1cb72bc20e0796c2bb10034e514f76364e902898diff --git a/solr/licenses/zookeeper-jute-3.7.0.jar.sha1 b/solr/licenses/zookeeper-jute-3.7.0.jar.sha1new file mode 100644index 00000000000..3a713693c67--- /dev/null+++ b/solr/licenses/zookeeper-jute-3.7.0.jar.sha1@@ -0,0 +1 @@+502176b97601e187a77936378ec52f554d386d0fdiff --git a/solr/solr-ref-guide/src/major-changes-in-solr-9.adoc b/solr/solr-ref-guide/src/major-changes-in-solr-9.adocindex 68692beca31..a22e957d16d 100644--- a/solr/solr-ref-guide/src/major-changes-in-solr-9.adoc+++ b/solr/solr-ref-guide/src/major-changes-in-solr-9.adoc@@ -154,6 +154,8 @@ _(raw; not yet edited)_* SOLR-15276: V2 API call to look up async request status restful style of "/cluster/command-status/1000" instead of "/cluster/command-status?requestid=1000".+* SOLR-15409: Zookeeper client libraries upgraded to 3.7.0, which may not be compatible with your existing server installations+=== Upgrade Prerequisites in Solr 9* Upgrade all collections in stateFormat=1 to stateFormat=2 *before* upgrading to Solr 9, as Solr 9 does not support thediff --git a/solr/solrj/src/java/org/apache/solr/client/solrj/io/stream/DrillStream.java b/solr/solrj/src/java/org/apache/solr/client/solrj/io/stream/DrillStream.javaindex 91e307e171f..f4f1ada88cc 100644--- a/solr/solrj/src/java/org/apache/solr/client/solrj/io/stream/DrillStream.java+++ b/solr/solrj/src/java/org/apache/solr/client/solrj/io/stream/DrillStream.java@@ -21,7 +21,6 @@ import java.util.ArrayList;import java.util.List;import java.util.Locale;-import org.apache.commons.lang.exception.ExceptionUtils;import org.apache.solr.client.solrj.io.Tuple;import org.apache.solr.client.solrj.io.comp.FieldComparator;import org.apache.solr.client.solrj.io.comp.StreamComparator;@@ -33,6 +32,7 @@ import org.apache.solr.client.solrj.io.stream.expr.StreamExpression;import org.apache.solr.client.solrj.io.stream.expr.StreamExpressionNamedParameter;import org.apache.solr.client.solrj.io.stream.expr.StreamExpressionValue;import org.apache.solr.client.solrj.io.stream.expr.StreamFactory;+import org.apache.solr.common.SolrException;import org.apache.solr.common.params.ModifiableSolrParams;import static org.apache.solr.common.params.CommonParams.DISTRIB;@@ -268,7 +268,7 @@ public class DrillStream extends CloudSolrStream implements Expressible {solrStreams.add(solrStream);});} catch (Exception e) {- Throwable rootCause = ExceptionUtils.getRootCause(e);+ Throwable rootCause = SolrException.getRootCause(e);if (rootCause instanceof IOException) {throw (IOException)rootCause;} else {diff --git a/solr/solrj/src/java/org/apache/solr/common/SolrException.java b/solr/solrj/src/java/org/apache/solr/common/SolrException.javaindex 2375710e13f..b86d48566c0 100644--- a/solr/solrj/src/java/org/apache/solr/common/SolrException.java+++ b/solr/solrj/src/java/org/apache/solr/common/SolrException.java@@ -212,7 +212,8 @@ public class SolrException extends RuntimeException {return null;}-++ // TODO: This doesn't handle cause loopspublic static Throwable getRootCause(Throwable t) {while (true) {Throwable cause = t.getCause();diff --git a/solr/solrj/src/java/org/apache/solr/common/cloud/ZkMaintenanceUtils.java b/solr/solrj/src/java/org/apache/solr/common/cloud/ZkMaintenanceUtils.javaindex 5d874a64a27..645b80dea83 100644--- a/solr/solrj/src/java/org/apache/solr/common/cloud/ZkMaintenanceUtils.java+++ b/solr/solrj/src/java/org/apache/solr/common/cloud/ZkMaintenanceUtils.java@@ -33,8 +33,8 @@ import java.util.Locale;import java.util.function.Predicate;import java.util.regex.Pattern;-import org.apache.commons.lang.StringUtils;import org.apache.solr.client.solrj.SolrServerException;+import org.apache.solr.common.StringUtils;import org.apache.zookeeper.KeeperException;import org.apache.zookeeper.data.Stat;import org.slf4j.Logger;@@ -418,14 +418,19 @@ public class ZkMaintenanceUtils {// Will return empty string if the path is just "/"// Will return empty string if the path is just ""public static String getZkParent(String path) {+ if (StringUtils.isEmpty(path) || "/".equals(path)) {+ return "";+ }// Remove trailing slash if present.- if (StringUtils.endsWith(path, "/")) {- path = StringUtils.substringBeforeLast(path, "/");+ int endIndex = path.length() - 1;+ if (path.endsWith("/")) {+ endIndex--;}- if (StringUtils.contains(path, "/") == false) {+ int index = path.lastIndexOf("/", endIndex);+ if (index == -1) {return "";}- return (StringUtils.substringBeforeLast(path, "/"));+ return path.substring(0, index);}// Take into account Windows file separators when making a Znode's name.diff --git a/versions.lock b/versions.lockindex 43f6842a050..b0919f8c49c 100644--- a/versions.lock+++ b/versions.lock@@ -58,7 +58,6 @@ commons-cli:commons-cli:1.4 (1 constraints: a9041e2c)commons-codec:commons-codec:1.13 (3 constraints: 88269b79)commons-collections:commons-collections:3.2.2 (1 constraints: 09050236)commons-io:commons-io:2.8.0 (1 constraints: 0c050d36)-commons-lang:commons-lang:2.6 (1 constraints: 2a0d520d)commons-logging:commons-logging:1.1.3 (2 constraints: c8149e7f)de.l3s.boilerpipe:boilerpipe:1.1.0 (1 constraints: 0405f335)io.dropwizard.metrics:metrics-core:4.1.5 (5 constraints: 2543e4c0)@@ -69,14 +68,14 @@ io.dropwizard.metrics:metrics-jvm:4.1.5 (1 constraints: 0c050736)io.grpc:grpc-context:1.36.0 (3 constraints: 5a22231e)io.jaegertracing:jaeger-core:1.1.0 (1 constraints: 5c0d6c26)io.jaegertracing:jaeger-thrift:1.1.0 (1 constraints: 0405f335)-io.netty:netty-buffer:4.1.50.Final (6 constraints: 0555463a)-io.netty:netty-codec:4.1.50.Final (2 constraints: f0132581)-io.netty:netty-common:4.1.50.Final (8 constraints: 6d6ed7af)-io.netty:netty-handler:4.1.50.Final (2 constraints: 25171741)-io.netty:netty-resolver:4.1.50.Final (3 constraints: 9b2100cd)-io.netty:netty-transport:4.1.50.Final (5 constraints: 5a47c31d)-io.netty:netty-transport-native-epoll:4.1.50.Final (2 constraints: 25171741)-io.netty:netty-transport-native-unix-common:4.1.50.Final (2 constraints: fc194204)+io.netty:netty-buffer:4.1.59.Final (6 constraints: 32558a4d)+io.netty:netty-codec:4.1.59.Final (2 constraints: f9136481)+io.netty:netty-common:4.1.59.Final (8 constraints: ac6e00d5)+io.netty:netty-handler:4.1.59.Final (2 constraints: 2e175641)+io.netty:netty-resolver:4.1.59.Final (3 constraints: ad21e6ce)+io.netty:netty-transport:4.1.59.Final (5 constraints: 7e47082a)+io.netty:netty-transport-native-epoll:4.1.59.Final (2 constraints: 2e175641)+io.netty:netty-transport-native-unix-common:4.1.59.Final (2 constraints: 051a8104)io.opencensus:opencensus-api:0.28.0 (5 constraints: 21426a37)io.opencensus:opencensus-contrib-http-util:0.28.0 (3 constraints: f7265f07)io.opentracing:opentracing-api:0.33.0 (5 constraints: 4d3cfe52)@@ -171,8 +170,8 @@ org.apache.tika:tika-java7:1.24 (1 constraints: db04f730)org.apache.tika:tika-parsers:1.24 (1 constraints: db04f730)org.apache.tika:tika-xmp:1.24 (1 constraints: db04f730)org.apache.xmlbeans:xmlbeans:3.1.0 (1 constraints: 0605fd35)-org.apache.zookeeper:zookeeper:3.6.2 (1 constraints: 0d050e36)-org.apache.zookeeper:zookeeper-jute:3.6.2 (1 constraints: 8b0d3928)+org.apache.zookeeper:zookeeper:3.7.0 (1 constraints: 0c050f36)+org.apache.zookeeper:zookeeper-jute:3.7.0 (1 constraints: 8a0d3a28)org.aspectj:aspectjrt:1.8.0 (1 constraints: 0b050836)org.bitbucket.b_c:jose4j:0.6.5 (1 constraints: 0d050236)org.bouncycastle:bcmail-jdk15on:1.64 (1 constraints: df04ff30)@@ -223,7 +222,7 @@ org.ow2.asm:asm:7.2 (2 constraints: 4e19d5db)org.ow2.asm:asm-commons:7.2 (1 constraints: 6b0f7267)org.rrd4j:rrd4j:3.5 (1 constraints: ac04252c)org.slf4j:jcl-over-slf4j:1.7.24 (1 constraints: 4005473b)-org.slf4j:slf4j-api:1.7.24 (14 constraints: ccafc13c)+org.slf4j:slf4j-api:1.7.24 (14 constraints: c8af2e3b)org.tallison:jmatio:1.5 (1 constraints: aa041f2c)org.threeten:threetenbp:1.5.0 (4 constraints: f82b9e86)org.tukaani:xz:1.8 (1 constraints: ad04222c)diff --git a/versions.props b/versions.propsindex 7837c24ab73..199f6b2aac1 100644--- a/versions.props+++ b/versions.props@@ -93,7 +93,7 @@ org.apache.pdfbox:jempbox=1.8.16org.apache.poi:*=4.1.1org.apache.tika:*=1.24org.apache.xmlbeans:xmlbeans=3.1.0-org.apache.zookeeper:*=3.6.2+org.apache.zookeeper:*=3.7.0org.asciidoctor:asciidoctorj=1.6.2org.aspectj:aspectjrt=1.8.0org.bitbucket.b_c:jose4j=0.6.5