Skip to content

Commit

Permalink
Do not specify SO_LINGER timeout, JVM default will be used
Browse files Browse the repository at this point in the history
When SO_LINGER >= 0 this will specify a timeout value, in seconds (linger interval).
The linger interval is the timeout for the close method to **block**
while the OS attempts to transmit the unsent data. When **0** the OS will not attempt
to transmit the unsend data.
When SO_LINGER < 0, then the close method does not wait until unsent data is
transmitted, but if possible the OS will transmit any unsent data before
the connection is closed.
More information StandardSocketOptions#SO_LINGER
  • Loading branch information
violetagg committed Sep 18, 2017
1 parent 0f6d061 commit 59beb9d
Showing 1 changed file with 0 additions and 1 deletion.
1 change: 0 additions & 1 deletion src/main/java/reactor/ipc/netty/options/ServerOptions.java
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,6 @@ private final void defaultServerOptions(ServerBootstrap bootstrap) {
.childOption(ChannelOption.SO_SNDBUF, 1024 * 1024)
.childOption(ChannelOption.AUTO_READ, false)
.childOption(ChannelOption.SO_KEEPALIVE, true)
.childOption(ChannelOption.SO_LINGER, 0)
.childOption(ChannelOption.TCP_NODELAY, true)
.childOption(ChannelOption.CONNECT_TIMEOUT_MILLIS, 30000);
}
Expand Down

0 comments on commit 59beb9d

Please sign in to comment.