hc-httpclient-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Wittmann Armin" <awittm...@ethz.ch>
Subject after 60000 requests more than 700 sockets in CLOSE_WAIT
Date Tue, 04 Sep 2007 11:22:53 GMT

Hi httpclient-Team

over the last 4 days I made a long term test for
our new software release.

This software ist integrated into an Apache Tomcat 5.5
(as a servlet receiving requests, transform them and
sending out other GET-requests through http-client) and should
run very reliable and without any resource leaks.

After finishing this test cycle I noticed that there
remained over 700 sockets in CLOSE_WAIT state
 (Linux -> netstat -a -p). 
Due to the identified PID and the destination ip number it is
obvious that these sockets have been caused/used
by the program part using http-client-3.0.1.

I am not a real network crack so I don't know if I need
to bother about this. Since the software/tomcat is itended
to run months (7x24) without necessarily rebooting it
I am not shure if I will run out of network resources.

Can somebody help in this subject?

By the way: all 60000 http-GET-requests worked well and there
	were no other problems at all.



My Code (simplified):
this code ist executed for every single request

HttpConnectionManager connectionManager = new
HttpClient client = new HttpClient(clientParams, connectionManager);
HttpMethod method =  = new GetMethod();
try {
} catch (Exception e) {
	failed = true;
	throw new Exception(...);
} finally {
	if (failed) method.abort();
	client = null;

try {
	responseString = method.getResponseBodyAsString();
} catch (Exception e) {
	throw new Exception(...);
} finally {
	method = null;

To unsubscribe, e-mail: httpclient-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: httpclient-user-help@jakarta.apache.org

View raw message