Hi Andrea,

The MultiThreadedHttpConnectionManager creates connections and keeps them open as long as it can. The number of connections kept open can be configured using setMaxConnectionsPerHost() and setMaxTotalConnections(). The issue of the sockets in the CLOSE_WAIT state seems to be a side effect of linux. In particular it seems to keep sockets is this state even after the java.net.Socket has been closed. I don't think there is much that can be done about it.

Mike

On Wednesday, October 8, 2003, at 08:55 AM, Andrea Fabris wrote:

Hi everyone!
I'd like to ask some question about http pool in commons-httpclient.
As i read, MultiTrheadedHttpConnectionManager is the manger responsible for
handling the connection in a multi-thread enviroment.
I want to use this to create a private HttpClient property in a servlet
class, so each servlet thread can use a different socket to communicate with
a remote http server.
Now i monitored my enviroment to check the connection status and i found
that, when i don't use the servlet, some connection from servlet to remote
hosts remain up in CLOSE_WAIT state.
I want to ask you if this beahaviour is correct, because doing so the
manager uses machine resources even when there are no active requestes for
connection for a long time.
My enviroment is:
OS: linux redhat 8.2 with kernel 2.4.18
JVM: 1.3.1_07-b02
Tomcat 3.3.1
Commons-HttpClient 2.0rc1


Thanx for your help

Regards
Andrea Fabris
Sytel Reply - Italy




-- Email.it, the professional e-mail, gratis per te: http://www.email.it/f

Sponsor:
Conto Arancio. Zero spese, stessa banca, più interessi.
Clicca qui: http://adv.email.it/cgi-bin/foclick.cgi?mid=657&d=8-10

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to