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

hossman pushed a commit to branch branch_9x
in repository https://gitbox.apache.org/repos/asf/solr.git


The following commit(s) were added to refs/heads/branch_9x by this push:
     new 92c6765974f SOLR-17744: Fix 
AbstractCollectionsAPIDistributedZkTestBase.addReplicaTest to check that 
replicas become active
92c6765974f is described below

commit 92c6765974f569c906d6ea9fdfa9882a32877fec
Author: Chris Hostetter <[email protected]>
AuthorDate: Tue Apr 29 16:00:43 2025 -0700

    SOLR-17744: Fix AbstractCollectionsAPIDistributedZkTestBase.addReplicaTest 
to check that replicas become active
    
    This ensures internal recovery requests are not still in process when we 
try to shutdown the cluster
    
    (cherry picked from commit aaf69dc99911edd38e9b4c9f85f8f8a8fc2d1874)
---
 .../api/collections/AbstractCollectionsAPIDistributedZkTestBase.java    | 2 ++
 1 file changed, 2 insertions(+)

diff --git 
a/solr/test-framework/src/java/org/apache/solr/cloud/api/collections/AbstractCollectionsAPIDistributedZkTestBase.java
 
b/solr/test-framework/src/java/org/apache/solr/cloud/api/collections/AbstractCollectionsAPIDistributedZkTestBase.java
index 41b54f988e3..900171eb4c7 100644
--- 
a/solr/test-framework/src/java/org/apache/solr/cloud/api/collections/AbstractCollectionsAPIDistributedZkTestBase.java
+++ 
b/solr/test-framework/src/java/org/apache/solr/cloud/api/collections/AbstractCollectionsAPIDistributedZkTestBase.java
@@ -656,6 +656,7 @@ public abstract class 
AbstractCollectionsAPIDistributedZkTestBase extends SolrCl
             .process(cluster.getSolrClient());
     newReplica = grabNewReplica(response, getCollectionState(collectionName));
     assertNotNull(newReplica);
+    cluster.waitForActiveCollection(collectionName, 2, 6);
 
     try (SolrClient coreclient = getHttpSolrClient(newReplica.getBaseUrl())) {
       CoreAdminResponse status = 
CoreAdminRequest.getStatus(newReplica.getStr("core"), coreclient);
@@ -697,6 +698,7 @@ public abstract class 
AbstractCollectionsAPIDistributedZkTestBase extends SolrCl
     newReplica = grabNewReplica(response, getCollectionState(collectionName));
     assertEquals(
         "'core' should be 'propertyDotName' ", "propertyDotName", 
newReplica.getStr("core"));
+    cluster.waitForActiveCollection(collectionName, 2, 7);
   }
 
   private Replica grabNewReplica(CollectionAdminResponse response, 
DocCollection docCollection) {

Reply via email to