-Re: NettyServer not setting TCP keep-alive leading to leaked connections
James Baldassari 2012-03-01, 19:27
I read the thread you referenced. So the root cause of the problem is that
the firewall is terminating the connection without doing a proper TCP
This probably isn't a very common problem, but it seems like enabling TCP
keepalives in NettyServer (and on the client side as well) is a good idea
in general. Are you sure that keepalives aren't enabled by default in
Netty? I searched for a few minutes but couldn't find any documentation on
it. Have you actually seen this socket leak with Avro when behind a
We might want to also consider allowing the ServerBootstrap to be passed
into NettyServer via constructor or setter method. That way these types of
settings could be tweaked without any Avro code changes.
Would you mind creating an issue for this?
On Wed, Feb 29, 2012 at 3:20 PM, Frank Grimes <[EMAIL PROTECTED]>wrote:
> Hi All,
> I think that NettyServer needs to be changed to include the following line:
> bootstrap.setOption("child.keepAlive", true);
> Otherwise, it'll be susceptible to the following problem:
> http://mail-archives.apache.org/mod_mbox/incubator-flume-user/201201.mbox/<[EMAIL PROTECTED]>
> Not sure if HttpServer is also affected by this because I haven't yet dug
> into the Jetty code to see if it sets TCP keep-alive on its sockets.
> Let me know if I should file a JIRA and/or provide a patch...
> Frank Grimes