mirror of
https://github.com/apache/lucene.git
synced 2025-02-21 17:46:28 +00:00
SOLR-3869: A PeerSync attempt to it's replicas by a candidate leader should not fail on o.a.http.conn.ConnectTimeoutException.
Also turn on the use of jetty test mode with sys prop that was no longer being used - this improves the situation when we restart jetty. Both of these fixes should help our FreeBSD continuous build. git-svn-id: https://svn.apache.org/repos/asf/lucene/dev/trunk@1389160 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
f025322f81
commit
c656ba11bf
@ -337,6 +337,9 @@ Bug Fixes
|
|||||||
|
|
||||||
* SOLR-3783: Fixed Pivot Faceting to work with facet.missing=true (hossman)
|
* SOLR-3783: Fixed Pivot Faceting to work with facet.missing=true (hossman)
|
||||||
|
|
||||||
|
* SOLR-3869: A PeerSync attempt to it's replicas by a candidate leader should
|
||||||
|
not fail on o.a.http.conn.ConnectTimeoutException. (Mark Miller)
|
||||||
|
|
||||||
Other Changes
|
Other Changes
|
||||||
----------------------
|
----------------------
|
||||||
|
|
||||||
|
@ -28,6 +28,7 @@ import java.util.Set;
|
|||||||
|
|
||||||
import org.apache.http.NoHttpResponseException;
|
import org.apache.http.NoHttpResponseException;
|
||||||
import org.apache.http.client.HttpClient;
|
import org.apache.http.client.HttpClient;
|
||||||
|
import org.apache.http.conn.ConnectTimeoutException;
|
||||||
import org.apache.lucene.util.BytesRef;
|
import org.apache.lucene.util.BytesRef;
|
||||||
import org.apache.solr.client.solrj.SolrServerException;
|
import org.apache.solr.client.solrj.SolrServerException;
|
||||||
import org.apache.solr.client.solrj.impl.HttpClientUtil;
|
import org.apache.solr.client.solrj.impl.HttpClientUtil;
|
||||||
@ -299,7 +300,7 @@ public class PeerSync {
|
|||||||
if (cantReachIsSuccess && sreq.purpose == 1 && srsp.getException() instanceof SolrServerException) {
|
if (cantReachIsSuccess && sreq.purpose == 1 && srsp.getException() instanceof SolrServerException) {
|
||||||
Throwable solrException = ((SolrServerException) srsp.getException())
|
Throwable solrException = ((SolrServerException) srsp.getException())
|
||||||
.getRootCause();
|
.getRootCause();
|
||||||
if (solrException instanceof ConnectException
|
if (solrException instanceof ConnectException || solrException instanceof ConnectTimeoutException
|
||||||
|| solrException instanceof NoHttpResponseException) {
|
|| solrException instanceof NoHttpResponseException) {
|
||||||
log.warn(msg() + " couldn't connect to " + srsp.getShardAddress() + ", counting as success");
|
log.warn(msg() + " couldn't connect to " + srsp.getShardAddress() + ", counting as success");
|
||||||
|
|
||||||
|
@ -81,6 +81,7 @@ public abstract class SolrTestCaseJ4 extends LuceneTestCase {
|
|||||||
@BeforeClass
|
@BeforeClass
|
||||||
@SuppressWarnings("unused")
|
@SuppressWarnings("unused")
|
||||||
private static void beforeClass() {
|
private static void beforeClass() {
|
||||||
|
System.setProperty("jetty.testMode", "true");
|
||||||
setupLogging();
|
setupLogging();
|
||||||
startTrackingSearchers();
|
startTrackingSearchers();
|
||||||
startTrackingZkClients();
|
startTrackingZkClients();
|
||||||
@ -95,6 +96,7 @@ public abstract class SolrTestCaseJ4 extends LuceneTestCase {
|
|||||||
endTrackingSearchers();
|
endTrackingSearchers();
|
||||||
endTrackingZkClients();
|
endTrackingZkClients();
|
||||||
resetFactory();
|
resetFactory();
|
||||||
|
System.clearProperty("jetty.testMode");
|
||||||
}
|
}
|
||||||
|
|
||||||
private static boolean changedFactory = false;
|
private static boolean changedFactory = false;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user