Skip to content

Commit

Permalink
Modify the idle state connection close to log the connection that
Browse files Browse the repository at this point in the history
is being closed

Signed-off-by: Chris Larsen <clarsen@yahoo-inc.com>
  • Loading branch information
manolama committed Feb 16, 2015
1 parent 52e43e0 commit 5c5b283
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/tsd/RpcHandler.java
Expand Up @@ -582,8 +582,10 @@ public void execute(TSDB tsdb, HttpQuery query) throws IOException {
@Override
public void channelIdle(ChannelHandlerContext ctx, IdleStateEvent e) {
if (e.getState() == IdleState.ALL_IDLE) {
LOG.debug("Closed idle socket.");
final String channel_info = e.getChannel().toString();
LOG.debug("Closing idle socket: " + channel_info);
e.getChannel().close();
LOG.info("Closed idle socket: " + channel_info);
}
}

Expand Down

0 comments on commit 5c5b283

Please sign in to comment.