You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucene.apache.org by ma...@apache.org on 2020/07/27 20:30:44 UTC

[lucene-solr] branch reference_impl updated: @402 Finally, wait for *anything* outstanding.

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

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


The following commit(s) were added to refs/heads/reference_impl by this push:
     new 166c00d  @402 Finally, wait for *anything* outstanding.
166c00d is described below

commit 166c00de3f2b74421709de688982ab097b960cbc
Author: markrmiller@gmail.com <ma...@gmail.com>
AuthorDate: Mon Jul 27 15:30:30 2020 -0500

    @402 Finally, wait for *anything* outstanding.
---
 solr/core/src/java/org/apache/solr/update/SolrCmdDistributor.java     | 3 +--
 .../src/test/org/apache/solr/client/solrj/LargeVolumeTestBase.java    | 4 +++-
 2 files changed, 4 insertions(+), 3 deletions(-)

diff --git a/solr/core/src/java/org/apache/solr/update/SolrCmdDistributor.java b/solr/core/src/java/org/apache/solr/update/SolrCmdDistributor.java
index 0f35a47..28dacdc 100644
--- a/solr/core/src/java/org/apache/solr/update/SolrCmdDistributor.java
+++ b/solr/core/src/java/org/apache/solr/update/SolrCmdDistributor.java
@@ -87,8 +87,7 @@ public class SolrCmdDistributor implements Closeable {
   public void finish() {
     assert !finished : "lifecycle sanity check";
     finished = true;
-
-   // blockAndDoRetries();
+    solrClient.waitForOutstandingRequests();
   }
   
   public void close() {
diff --git a/solr/solrj/src/test/org/apache/solr/client/solrj/LargeVolumeTestBase.java b/solr/solrj/src/test/org/apache/solr/client/solrj/LargeVolumeTestBase.java
index f54fc0b..1c60158 100644
--- a/solr/solrj/src/test/org/apache/solr/client/solrj/LargeVolumeTestBase.java
+++ b/solr/solrj/src/test/org/apache/solr/client/solrj/LargeVolumeTestBase.java
@@ -25,6 +25,7 @@ import org.apache.solr.EmbeddedSolrServerTestBase;
 import org.apache.solr.client.solrj.embedded.EmbeddedSolrServer;
 import org.apache.solr.client.solrj.response.QueryResponse;
 import org.apache.solr.client.solrj.response.UpdateResponse;
+import org.apache.solr.common.ParWork;
 import org.apache.solr.common.SolrInputDocument;
 import org.junit.Test;
 import org.slf4j.Logger;
@@ -40,7 +41,7 @@ public abstract class LargeVolumeTestBase extends EmbeddedSolrServerTestBase
 
   // for real load testing, make these numbers bigger
   static final int numdocs = 100; //1000 * 1000;
-  static final int threadCount = 5;
+  static final int threadCount = TEST_NIGHTLY ? 5 : 3;
 
   @Test
   public void testMultiThreaded() throws Exception {
@@ -118,6 +119,7 @@ public abstract class LargeVolumeTestBase extends EmbeddedSolrServerTestBase
         resp = client.optimize();
         assertEquals(0, resp.getStatus());
         } catch (Exception e) {
+          ParWork.propegateInterrupt(e);
           // a commit/optimize can fail with a too many warming searchers exception
           if (log.isInfoEnabled()) {
             log.info("Caught benign exception during commit: {}", e.getMessage());