[ https://issues.apache.org/jira/browse/KAFKA-2817?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15002507#comment-15002507 ]
ASF GitHub Bot commented on KAFKA-2817: --------------------------------------- GitHub user ijuma opened a pull request: https://github.com/apache/kafka/pull/511 KAFKA-2817; Check if socketChannel is connected in `SslTransportLayer.close` This avoids spurious log warning messages. Also tweak log message if wrapResult.getStatus != CLOSED. You can merge this pull request into a Git repository by running: $ git pull https://github.com/ijuma/kafka kafka-2817-unconnected-ssl-transport-layer-close Alternatively you can review and apply these changes as the patch at: https://github.com/apache/kafka/pull/511.patch To close this pull request, make a commit to your master/trunk branch with (at least) the following in the commit message: This closes #511 ---- commit 36bd18b0d6b1de88f06227f90fdc020611330964 Author: Ismael Juma <ism...@juma.me.uk> Date: 2015-11-12T17:31:43Z Check if socketChannel is connected in `SslTransportLayer.close` This avoids spurious log warning messages. Also tweak log message if wrapResult.getStatus != CLOSED. ---- > Closing an unconnected SslTransport get an invalid close state exception > ------------------------------------------------------------------------ > > Key: KAFKA-2817 > URL: https://issues.apache.org/jira/browse/KAFKA-2817 > Project: Kafka > Issue Type: Bug > Components: core > Reporter: Jun Rao > Assignee: Ismael Juma > Fix For: 0.9.0.0 > > > Saw the following in our system test. When shutting down a broker, in a short > window, the controller can't establish socket connection to the shutdown > broker and tries to close it. It hit the following exception. This may leak > the underlying socket. > [2015-11-11 07:24:17,253] WARN Failed to send SSL Close message > (org.apache.kafka.common.network.SslTransportLayer) > java.io.IOException: Invalid close state, will not send network data. > at > org.apache.kafka.common.network.SslTransportLayer.close(SslTransportLayer.java:156) > at > org.apache.kafka.common.network.KafkaChannel.close(KafkaChannel.java:50) > at org.apache.kafka.common.network.Selector.close(Selector.java:448) > at org.apache.kafka.common.network.Selector.poll(Selector.java:316) > at org.apache.kafka.clients.NetworkClient.poll(NetworkClient.java:270) > at > kafka.utils.NetworkClientBlockingOps$.recurse$1(NetworkClientBlockingOps.scala:128) > at > kafka.utils.NetworkClientBlockingOps$.kafka$utils$NetworkClientBlockingOps$$pollUntilFound$extension(NetworkClientBlockingOps.scala:139) > at > kafka.utils.NetworkClientBlockingOps$.kafka$utils$NetworkClientBlockingOps$$pollUntil$extension(NetworkClientBlockingOps.scala:105) > at > kafka.utils.NetworkClientBlockingOps$.blockingReady$extension(NetworkClientBlockingOps.scala:58) > at > kafka.controller.RequestSendThread.brokerReady(ControllerChannelManager.scala:225) > at > kafka.controller.RequestSendThread.liftedTree1$1(ControllerChannelManager.scala:172) > at > kafka.controller.RequestSendThread.doWork(ControllerChannelManager.scala:171) > at kafka.utils.ShutdownableThread.run(ShutdownableThread.scala:63) -- This message was sent by Atlassian JIRA (v6.3.4#6332)