Apache Lucene open-source search software
SOLR-9310: unhandled exception during parallel indexing
Noble Paul61e1f095e937
diff --git a/solr/core/src/test/org/apache/solr/cloud/PeerSyncReplicationTest.java b/solr/core/src/test/org/apache/solr/cloud/PeerSyncReplicationTest.javaindex abdd646a6e3..f85b7f1b7ef 100644--- a/solr/core/src/test/org/apache/solr/cloud/PeerSyncReplicationTest.java+++ b/solr/core/src/test/org/apache/solr/cloud/PeerSyncReplicationTest.java@@ -177,13 +177,14 @@ public class PeerSyncReplicationTest extends AbstractFullDistribZkTestBase {new Thread(() -> {try {for (int i = 0; i < numDocs; i++) {- indexDoc(id, docId, i1, 50, tlong, 50, t1, "document number " + docId++);+ indexDoc(id, docId, i1, 50, tlong, 50, t1, "document number " + docId);+ docId++;// slow down adds, to get documents indexed while in PeerSyncThread.sleep(100);}} catch (Exception e) {- throw new RuntimeException(e);-+ log.error("Error indexing doc in background", e);+ //Throwing an error here will kill the thread}}, getClassName()).start();