3
0

Make network connections keepalive (close #11)

This commit is contained in:
Prototik 2015-06-29 20:47:12 +07:00
parent 50bc729381
commit 499c680b58

View File

@ -86,6 +86,15 @@
if (this.channel.isOpen())
{
this.channel.close();
@@ -254,7 +288,7 @@
{
;
}
-
+ try { p_initChannel_1_.config().setOption(ChannelOption.SO_KEEPALIVE, true); } catch (ChannelException ignored) {}
try
{
p_initChannel_1_.config().setOption(ChannelOption.TCP_NODELAY, Boolean.valueOf(false));
@@ -322,6 +356,13 @@
return channel;
}