Lowell Kirsh wrote: > So I'm trying to use just a single HttpClient for my entire > application. When I had one HttpClient per request, I would set the > per-Method timeouts on the HttpClient itself, but now that I'm using > only a single HttpClient, I'm not sure how to go about setting the > timeouts. I'd like to set the connection timeout and the 'so' timeouts > for each HttpMethod that I execute. I can see how to set the 'so' > timeout by calling method.getParams().setSoTimeout(), but can I set > the connection timeout in a similar way?
Yes, set the parameter named http://jakarta.apache.org/commons/httpclient/apidocs/org/apache/commons/httpclient/params/HttpConnectionParams.html#CONNECTION_TIMEOUT in the method params. There is no convenience method like for SO timeout, but it should work anyway. cheers, Roland --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
