mirror of https://github.com/apache/kafka.git
kafka-2096; Enable keepalive socket option for broker to prevent socket leak; patched by Allen Wang; reviewed by Jun Rao
This commit is contained in:
parent
6880f66c97
commit
194d1fc030
|
|
@ -308,6 +308,7 @@ private[kafka] class Acceptor(val host: String,
|
|||
connectionQuotas.inc(socketChannel.socket().getInetAddress)
|
||||
socketChannel.configureBlocking(false)
|
||||
socketChannel.socket().setTcpNoDelay(true)
|
||||
socketChannel.socket().setKeepAlive(true)
|
||||
socketChannel.socket().setSendBufferSize(sendBufferSize)
|
||||
|
||||
debug("Accepted connection from %s on %s. sendBufferSize [actual|requested]: [%d|%d] recvBufferSize [actual|requested]: [%d|%d]"
|
||||
|
|
|
|||
Loading…
Reference in New Issue