@Override public void userEventTriggered(ChannelHandlerContext ctx, Object evt) throws Exception { if (evt instanceof PushUserAuth) { authEvent = (PushUserAuth) evt; } super.userEventTriggered(ctx, evt); }
@Override public void userEventTriggered(ChannelHandlerContext ctx, Object evt) throws Exception { super.userEventTriggered(ctx, evt); if (evt instanceof IdleStateEvent) { ctx.close(); } } }
@Override public void userEventTriggered(ChannelHandlerContext ctx, Object evt) throws Exception { if (evt instanceof ChannelInputShutdownEvent) { // The decodeLast method is invoked when a channelInactive event is encountered. // This method is responsible for ending requests in some situations and must be called // when the input has been shutdown. channelInputClosed(ctx, false); } super.userEventTriggered(ctx, evt); }
@Override public void userEventTriggered(ChannelHandlerContext ctx, Object evt) throws Exception { try { super.userEventTriggered(ctx, evt); } finally { if (evt instanceof HttpLifecycleChannelHandler.CompleteEvent) { ctx.channel().attr(ATTR_STATE).set(null); } } } }
@Override public void userEventTriggered(ChannelHandlerContext ctx, Object evt) throws Exception { if (evt instanceof ChannelInputShutdownEvent) { // The decodeLast method is invoked when a channelInactive event is encountered. // This method is responsible for ending requests in some situations and must be called // when the input has been shutdown. channelInputClosed(ctx, false); } super.userEventTriggered(ctx, evt); }
@Override public void userEventTriggered(ChannelHandlerContext ctx, Object evt) throws Exception { if (evt instanceof PushUserAuth) { authEvent = (PushUserAuth) evt; } super.userEventTriggered(ctx, evt); }
@Override public void userEventTriggered(ChannelHandlerContext ctx, Object evt) throws Exception { try { super.userEventTriggered(ctx, evt); } finally { if (evt instanceof HttpLifecycleChannelHandler.CompleteEvent) { CurrentPassport.clearFromChannel(ctx.channel()); } } } }
@Override public void userEventTriggered(ChannelHandlerContext ctx, Object evt) throws Exception { super.userEventTriggered(ctx, evt); if (evt instanceof IdleStateEvent) { ctx.close(); } } }
@Override public void userEventTriggered(ChannelHandlerContext ctx, Object evt) throws Exception { if (evt instanceof IdleStateEvent) { final CurrentPassport passport = CurrentPassport.fromChannel(ctx.channel()); if (passport != null) { passport.add(PassportState.SERVER_CH_IDLE_TIMEOUT); } } super.userEventTriggered(ctx, evt); } }
@Override public void userEventTriggered(ChannelHandlerContext ctx, Object evt) throws Exception { if (evt == MaxInboundConnectionsHandler.CONNECTION_THROTTLED_EVENT) { connectionThrottled.increment(); } else if (evt instanceof IdleStateEvent) { connectionIdleTimeout.increment(); } super.userEventTriggered(ctx, evt); } }
@Override public void userEventTriggered(ChannelHandlerContext ctx, Object evt) throws Exception { if (evt instanceof HttpLifecycleChannelHandler.StartEvent) { incrementCurrentRequestsInFlight(ctx); } else if (evt instanceof HttpLifecycleChannelHandler.CompleteEvent) { decrementCurrentRequestsIfOneInflight(ctx); } super.userEventTriggered(ctx, evt); }
@Override public void userEventTriggered(ChannelHandlerContext ctx, Object evt) throws Exception { try { super.userEventTriggered(ctx, evt); } finally { if (evt instanceof HttpLifecycleChannelHandler.CompleteEvent) { ctx.channel().attr(ATTR_STATE).set(null); } } } }
@Override public void userEventTriggered(ChannelHandlerContext ctx, Object evt) throws Exception { if (evt instanceof HttpRequestReadTimeoutEvent) { CurrentPassport.fromChannel(ctx.channel()).add(PassportState.IN_REQ_READ_TIMEOUT); removeInternalHandler(ctx); httpRequestReadTimeoutCounter.increment(); } super.userEventTriggered(ctx, evt); }
@Override public void userEventTriggered(ChannelHandlerContext ctx, Object evt) throws Exception { try { super.userEventTriggered(ctx, evt); } finally { if (evt instanceof HttpLifecycleChannelHandler.CompleteEvent) { CurrentPassport.clearFromChannel(ctx.channel()); } } } }
@Override public void userEventTriggered(ChannelHandlerContext ctx, Object evt) throws Exception { if (evt instanceof IdleStateEvent) { final CurrentPassport passport = CurrentPassport.fromChannel(ctx.channel()); if (passport != null) { passport.add(PassportState.SERVER_CH_IDLE_TIMEOUT); } } super.userEventTriggered(ctx, evt); } }
@Override public void userEventTriggered(ChannelHandlerContext ctx, Object evt) throws Exception { if (!sslInitDone && (evt instanceof SslHandshakeCompletionEvent)) { SslHandshakeCompletionEvent e = (SslHandshakeCompletionEvent) evt; if (e.isSuccess()) { sslInitDone = true; ctx.fireChannelActive(); } else { RedisConnection connection = RedisConnection.getFrom(ctx.channel()); connection.getConnectionPromise().tryFailure(e.cause()); } } super.userEventTriggered(ctx, evt); }
@Override public void userEventTriggered(ChannelHandlerContext ctx, Object evt) throws Exception { if (!sslInitDone && (evt instanceof SslHandshakeCompletionEvent)) { SslHandshakeCompletionEvent e = (SslHandshakeCompletionEvent) evt; if (e.isSuccess()) { sslInitDone = true; ctx.fireChannelActive(); } else { RedisConnection connection = RedisConnection.getFrom(ctx.channel()); connection.getConnectionPromise().tryFailure(e.cause()); } } super.userEventTriggered(ctx, evt); }
@Override public void userEventTriggered(ChannelHandlerContext ctx, Object evt) throws Exception { if (evt instanceof HttpLifecycleChannelHandler.StartEvent) { incrementCurrentRequestsInFlight(ctx); } else if (evt instanceof HttpLifecycleChannelHandler.CompleteEvent) { decrementCurrentRequestsIfOneInflight(ctx); } super.userEventTriggered(ctx, evt); }
@Override public void userEventTriggered(ChannelHandlerContext ctx, Object evt) throws Exception { if (evt == MaxInboundConnectionsHandler.CONNECTION_THROTTLED_EVENT) { connectionThrottled.increment(); } else if (evt instanceof IdleStateEvent) { connectionIdleTimeout.increment(); } super.userEventTriggered(ctx, evt); } }
@Override public void userEventTriggered(ChannelHandlerContext ctx, Object evt) throws Exception { if (evt instanceof HttpRequestReadTimeoutEvent) { CurrentPassport.fromChannel(ctx.channel()).add(PassportState.IN_REQ_READ_TIMEOUT); removeInternalHandler(ctx); httpRequestReadTimeoutCounter.increment(); } super.userEventTriggered(ctx, evt); }