Hi, I am using Http Commons to implement my http client and observe that after running the client for large number of request connections are left in close_wait stage. I searched through archives and noticed that following were suggested:
1. Reuse instances of HttpClient or the associated HttpConnectionManager, this may have threading implications. I do that. 2. Do closeidleConnections(long timeout) or customIdleConnectionTimeout thread I do closeIdleConnections(20*1000). Please do tell if anything else needs to be done for this solution. 3. Add a "Connection: close" and/or "Proxy-Connection: close" header to all methods. This should work in most cases, assuming that the server echoes the header in the response. I don't want to do this as can't take the performance hit. Is there any other way or do I need to do anything else in first 2 solutions so that it works for me. I am using a Jetty based server for the response side. Thanks, Pankaj Arora
