commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Michael Becke <>
Subject Re: [HttpClient] Lifetime of an unused connection
Date Sat, 20 Nov 2004 23:40:47 GMT
Hi Tom,

In HttpClient 2.0 connections are never closed/deleted from a  
MultiThreadedHttpConnectionManager until it is shutdown.  Things like  
keep-alive settings and exceptions will cause connections to be closed,  
but they will still be returned to the connection manager.

HttpClient 3.0 (just about to be 3.0 beta1) adds the ability to close  
idle connections.  Have a look at the following for some more details:





On Nov 19, 2004, at 5:00 AM, Tom van den Berge wrote:

> Hi,
> When using a MultiThreadedHttpConnectionManager for an HttpClient,  
> connections that are used and released again are placed back in the  
> pool again, so they can be reused. I was wondering for how long unused  
> connections will remain in the pool. In other words, what is causing a  
> connection to be removed from the pool?
> I can imagine it might be caused by the read timeout of the socket, or  
> there may be a separate 'keep alive' setting? Also the remote host  
> might terminate the connection after some time, and how does that  
> influence the connection object in the pool?
> I'm talking about httpclient 2.0.2.
> Thanks,
> Tom
> ---------------------------------------------------------------------
> To unsubscribe, e-mail:
> For additional commands, e-mail:

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message