Hi wolfgang, HttpClient will correctly release connection, but you must let it know that the connection is no longer in use somehow. There are a couple of ways of doing this:
1. Read all the data from the connection. 2. Call releaseConnection on the method you executed. You should take a look at the documentation on the httpclient website (http://jakarta.apache.org/commons/httpclient/) and particularly the tutorial (http://jakarta.apache.org/commons/httpclient/tutorial.html) then the multithreading guide (http://jakarta.apache.org/commons/httpclient/threading.html) then if you're still having trouble check out the troubleshooting guide (http://jakarta.apache.org/commons/httpclient/troubleshooting.html) and finally if you still can't work it out send a wire trace through to the mailing list (see http://jakarta.apache.org/commons/httpclient/logging.html). Who says open source is never well documented? :) Hope that helps, Adrian Sutton, Software Engineer Ephox Corporation www.ephox.com -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Saturday, 21 June 2003 11:51 PM To: [EMAIL PROTECTED] Subject: [HttpClient] HttpClient doesn't release connection....!? Hi there, I've been developing a simple code (on Redhat7.3) accessing many web pages. The code instantiate 50 thread objects and httpclient is instantiated in each thread. If I run the code, httpclient doesn't finish...and the processes remains till I kill those processes. I checked it out by 'ps -efwww | grep java ' Of course, I'm using both the timeout of httpclient connection and releaseConnection() method. I'm guessing that HttpClient doesn't release Connection.... Thanks in advance wolfgang --------------------------------------------------------------------- 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]
