Fixing incorrect usage of connection and read timeout variables

git-svn-id: https://svn.apache.org/repos/asf/lucene/solr/trunk@786801 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Shalin Shekhar Mangar 2009-06-20 12:20:56 +00:00
parent 6981083fc3
commit a41fa5cac6
1 changed files with 2 additions and 2 deletions

View File

@ -114,8 +114,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 ? 20000 : Integer.parseInt(connTimeout)); //20 secs
mgr.getParams().setConnectionTimeout(readTimeout == null ? 5000 : Integer.parseInt(readTimeout)); //5 secs
mgr.getParams().setSoTimeout(readTimeout == null ? 20000 : Integer.parseInt(readTimeout)); //20 secs
mgr.getParams().setConnectionTimeout(connTimeout == null ? 5000 : Integer.parseInt(connTimeout)); //5 secs
HttpClient httpClient = new HttpClient(mgr);
if (client == null && connTimeout == null && readTimeout == null) client = httpClient;
return httpClient;