On Tue, 2010-06-15 at 13:50 -0700, KaiserSose wrote:
> 
> Sam Crawford wrote:
> > 
> > I don't see anything glaringly wrong there. What's HttpManagerCleaner
> > by the way? I assume this is some peripheral thread that cleans up
> > idle connections? Is this based upon IdleConnectionEvictor that Oleg
> > has posted here?
> > 
> 
> Yes it's the peripheral Thread ...
> 
> However I was talking to some colleagues today and we where discussing about
> the "usefulness" of pooling connections when there is a Load Balancer in the
> middle. The pool should be used in order to keep a "channel" open and to
> reuse a connection.
> 
> Now if any frontend contacts the load balancer and the load balancer put the
> calling frontend in communication with one of the servers behind him I will
> have the situation in which the pooled connection will be directly from the
> frontend to one of the servers, right? Now let's imagine this server fall
> down, what happens to my pooled connections to this server? The load
> balancer won't be called again right? 

The connection will become stale and will be automatically discarded if
the stale connection check is active or upon request execution failure.
Then, HttpClient will open a new connection.

> 
> As far as my component tips are to come back to the previous situation in
> which there is no pool and each connection won't be reused ... if I don't
> use anymore the ThreadSafeClientConnectionManager() should I call everytime
> the abort after having consumed the content on every get/post operation?
> 
> Do you think it's stupid to think to an architecture with a pool and a load
> balancer?
> 

No, it is not. You may want to reduce the keep alive time, but you
should still let HttpClient pool / re-use connections.

Oleg


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to