Apache Solr open-source search software
SOLR-16452: initialize missing PRS with version 0
Noble Paul3bdeff0317d0
diff --git a/solr/solrj-zookeeper/src/java/org/apache/solr/common/cloud/PerReplicaStatesFetcher.java b/solr/solrj-zookeeper/src/java/org/apache/solr/common/cloud/PerReplicaStatesFetcher.javaindex c9bf7d7f087..f959cab3e03 100644--- a/solr/solrj-zookeeper/src/java/org/apache/solr/common/cloud/PerReplicaStatesFetcher.java+++ b/solr/solrj-zookeeper/src/java/org/apache/solr/common/cloud/PerReplicaStatesFetcher.java@@ -33,7 +33,7 @@ public class PerReplicaStatesFetcher {try {if (current != null) {Stat stat = zkClient.exists(current.path, null, true);- if (stat == null) return new PerReplicaStates(path, -1, Collections.emptyList());+ if (stat == null) return new PerReplicaStates(path, 0, Collections.emptyList());if (current.cversion == stat.getCversion()) return current; // not modifiedZkStateReaderTest}Stat stat = new Stat();