hc-httpclient-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Roland Weber <ROLWE...@de.ibm.com>
Subject Re: Should NOT close connection, using HTTP/1.1?
Date Fri, 02 Dec 2005 06:27:53 GMT
Hi Chris,

it is not a warning, it is an information.
You're supposed to release the connection, no problem.

The connection manager decides whether the connection
gets closed or whether it remains open (connection re-use).
This is a performance optimization. It is the connection
manager that logs it should not close (but re-use) the
connection you have just released.

hope that explains it,
  Roland





Chris Ashurst <cashurst@thig.com> 
01.12.2005 18:37
Please respond to
"HttpClient User Discussion"


To
httpclient-user@jakarta.apache.org
cc

Subject
Should NOT close connection, using HTTP/1.1?






I'm sure this has been answered before, but after my request is sent and 
results are returned, the debug log message warns me about not closing 
the connection.

I'm currently using the following to close the connection:

if (method.hasBeenUsed() && method.isRequestSent()) {
                 method.releaseConnection();
}

I'm guessing the warning in the log is referring to the 
releaseConnection method, so what am I supposed to do in terms of 
releasing the connection if I'm not supposed to release it?

Thanks!

-- 
~Chris Ashurst
~~Tower Hill Insurance
~cashurst@thig.com

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




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


Mime
View raw message