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.
