You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucene.apache.org by no...@apache.org on 2021/10/27 06:35:47 UTC

[lucene-solr] 01/02: fixed the bug

This is an automated email from the ASF dual-hosted git repository.

noble pushed a commit to branch jira/SOLR15722
in repository https://gitbox.apache.org/repos/asf/lucene-solr.git

commit 757d06f1bdb4ce3a56f48b0eb074d1931627f49a
Author: Noble Paul <no...@gmail.com>
AuthorDate: Wed Oct 27 14:53:14 2021 +1100

    fixed the bug
---
 solr/core/src/java/org/apache/solr/cloud/overseer/SliceMutator.java | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/solr/core/src/java/org/apache/solr/cloud/overseer/SliceMutator.java b/solr/core/src/java/org/apache/solr/cloud/overseer/SliceMutator.java
index d0f08cc..c57cdbd 100644
--- a/solr/core/src/java/org/apache/solr/cloud/overseer/SliceMutator.java
+++ b/solr/core/src/java/org/apache/solr/cloud/overseer/SliceMutator.java
@@ -131,7 +131,8 @@ public class SliceMutator {
 
 
     if (coll.isPerReplicaState()) {
-      return new ZkWriteCommand(collection, coll.copyWithSlices(newSlices), PerReplicaStatesOps.deleteReplica(cnn, coll.getPerReplicaStates()) , true);
+      PerReplicaStatesOps replicaOps = PerReplicaStatesOps.deleteReplica(cnn, PerReplicaStates.fetch(coll.getZNode(), zkClient, coll.getPerReplicaStates()) );
+      return new ZkWriteCommand(collection, coll.copyWithSlices(newSlices), replicaOps, true);
     } else {
       return new ZkWriteCommand(collection, coll.copyWithSlices(newSlices));
     }