From 169b3252a06b362b7b41dd74aeabdf09d0f21dc9 Mon Sep 17 00:00:00 2001 From: Pierre Salagnac Date: Tue, 7 Jan 2025 19:10:26 +0100 Subject: [PATCH] Fix rarely flaky DeleteInactiveReplicaTest. The test was retrieving a replica from cluster state using core name instead of correct replica name. --- .../test/org/apache/solr/cloud/DeleteInactiveReplicaTest.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/solr/core/src/test/org/apache/solr/cloud/DeleteInactiveReplicaTest.java b/solr/core/src/test/org/apache/solr/cloud/DeleteInactiveReplicaTest.java index 8d3749b7eba..33bab69aeae 100644 --- a/solr/core/src/test/org/apache/solr/cloud/DeleteInactiveReplicaTest.java +++ b/solr/core/src/test/org/apache/solr/cloud/DeleteInactiveReplicaTest.java @@ -83,7 +83,7 @@ public void deleteInactiveReplicaTest() throws Exception { "Expected replica " + replica.getName() + " on down node to be removed from cluster state", collectionName, (n, c) -> { - Replica r = c.getReplica(replica.getCoreName()); + Replica r = c.getReplica(replica.getName()); return r == null || r.getState() != Replica.State.ACTIVE; }); @@ -96,7 +96,7 @@ public void deleteInactiveReplicaTest() throws Exception { "Expected deleted replica " + replica.getName() + " to be removed from cluster state", collectionName, (n, c) -> { - return c.getReplica(replica.getCoreName()) == null; + return c.getReplica(replica.getName()) == null; }); cluster.startJettySolrRunner(jetty);