Unfortunately, we are finding that connections that are reused from the pool 
contain cookie values that remain from prior connections. That is why I was 
curious if there was some particular approach recommended for making sure 
cookies don't persist among requests. 

The result so far has been duplicate cookie names with different values in 
subsequent requests after the first.

Thanks.

-----Original Message-----
From: Oleg Kalnichevski [mailto:[email protected]] 
Sent: Tuesday, April 05, 2011 11:58 AM
To: HttpClient User Discussion
Subject: Re: Connection Pool Event Listeners

On Mon, 2011-04-04 at 16:35 -0500, Neil Chaudhuri wrote:
> I am using ThreadSafeClientConnManager to manage a pool of connections to 
> serve multiple threads, but some of the requests and responses have cookies 
> set. Obviously, I would like to return the connections to the pool in the 
> same condition I retrieved them, which means removing those cookies before 
> connection release. To me, the cleanest way to accomplish this would be some 
> interceptor or listener that was registered for connection lease and release 
> events, but I don't see support for such a thing. Is there a way to 
> accomplish this? Or if not, what is the preferred approach to keep 
> connections stateless between trips to the pool?
> 
> Thanks.

I am not sure I understand your problem. HTTP cookies are _never_
persisted with connections kept alive in the pool.

Oleg


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

Reply via email to