mirror of
https://github.com/apache/lucene.git
synced 2025-02-28 21:39:25 +00:00
SOLR-1096 followup -- Change default connection timeout to 5 seconds and read timeout to 20 seconds
git-svn-id: https://svn.apache.org/repos/asf/lucene/solr/trunk@765483 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
67fa0ec527
commit
7769e35924
@ -110,8 +110,8 @@ public class SnapPuller {
|
||||
// no requests are kept waiting for an idle connection.
|
||||
mgr.getParams().setDefaultMaxConnectionsPerHost(10000);
|
||||
mgr.getParams().setMaxTotalConnections(10000);
|
||||
mgr.getParams().setSoTimeout(connTimeout == null ? 5000 : Integer.parseInt(connTimeout)); //5 secs
|
||||
mgr.getParams().setConnectionTimeout(readTimeout == null ? 10000 : Integer.parseInt(readTimeout)); //10 secs
|
||||
mgr.getParams().setSoTimeout(connTimeout == null ? 20000 : Integer.parseInt(connTimeout)); //20 secs
|
||||
mgr.getParams().setConnectionTimeout(readTimeout == null ? 5000 : Integer.parseInt(readTimeout)); //5 secs
|
||||
HttpClient httpClient = new HttpClient(mgr);
|
||||
if (client == null && connTimeout == null && readTimeout == null) client = httpClient;
|
||||
return httpClient;
|
||||
|
Loading…
x
Reference in New Issue
Block a user