On Thu, 2007-03-22 at 20:27 +0200, Mehmet Özer METİN wrote:
> Here is my code snippet, there is not so much change from
> ElementalHTTPServer. I have run this on port 8090 and try to proxy tomcat
> doc pages running on 8080 on Tomcat 5.5
>
Mehmet,
It all turned out to be pretty simple. You always close the connection
to the target server inside redirect in the finally clause. I am
surprised you manage to read any data at all. You should keep the
connection open until the response entity is fully read.
...
> DefaultHttpClientConnection conn = new
> DefaultHttpClientConnection();
> ConnectionReuseStrategy connStrategy = new
> DefaultConnectionReuseStrategy();
>
> try {
...
> return response;
> } finally {
> conn.close();
> }
>
> }
Hope this helps
Oleg
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]