Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [jetty-dev] jetty client socket fd leak issue

Hi,

On Fri, Sep 16, 2011 at 22:47, Simone Bordet <sbordet@xxxxxxxxxxx> wrote:
> Hi,
>
> On Fri, Sep 16, 2011 at 19:43, Junwei Sun <sun_junwei@xxxxxxxxx> wrote:
>> Hi All,
>>
>> Even if I have code "hc.setConnectBlocking(false)" there or not,
>> jetty client socket fd always leaks for the following URL.
>> After "ce.waitForDone()", there will left 3 socket fds.
>> The issue exists in both Jetty-7.5 and Jetty-8.0.
>>
>> Anyone have ideas? how to fix or work around?
>
> I do not think this is a problem.
> HttpClient opens and caches connections so even with no requests
> outstanding, there will probably be connections opened by previous
> requests.
> This is done for performances reason.
>
> Idle connections are eventually closed, and the timeout is configurable.

Note also that HttpClient will honor the "Connection: close" HTTP
header, either set by the client or the server, and close the
connection when such header is present.

Simon
-- 
http://bordet.blogspot.com
---
Finally, no matter how good the architecture and design are,
to deliver bug-free software with optimal performance and reliability,
the implementation technique must be flawless.   Victoria Livschitz


Back to the top