commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Michael Becke <>
Subject Re: HttpClient releaseConnection() problem
Date Wed, 25 Aug 2004 02:49:09 GMT
Hello Qingxian,

Are you getting an exception?  If so what does it look like?  If not 
how are you determining that the connection is being incorrectly 
released?  HttpMethods will automatically release connections when the 
response has been fully read.  If you post some sample code and a wire 
log <> we 
could get a better idea of what's going on.


On Aug 24, 2004, at 6:06 AM, Qingxian Wang wrote:

>> Hi,
>> I am using HttpClient 2.0.1 with JBoss-3.0.2_Tomcat-4.0.4.
>> I am using HttpClient to intercept the request from a Web browser to
>> change some request headers and use the PostMethod to post the request
>> contents to MicrosoftReport server.  Then, the reponse body
>> (PostMethod.getResponseBodyAsStream()) from the MicrosoftReport 
>> server is
>> written to response to the Web browser.
>> The following is the problem I encountered:
>> While reading from the InputStream object returned by
>> PostMethod.getResponseBodyAsStream() and writing to a 
>> HttpServletResponse
>> object, HttpClient releases HttpConnection and cause the response 
>> partly
>> writtent to the browser.
> 	I have set the socket time out to infinite by calling:
> httpClient.setTimeout(0).  I cannot figure out what is wrong.  Could 
> you
> help me.
> 	Thanks.
> 	Qingxian
> ---------------------------------------------------------------------
> To unsubscribe, e-mail:
> For additional commands, e-mail:

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message