@Override public void exceptionCaught(ChannelHandlerContext ctx, Throwable cause) throws Exception { super.exceptionCaught(ctx, cause); fireCompleteEventIfNotAlready(ctx, CompleteReason.EXCEPTION); }
@Override public void disconnect(ChannelHandlerContext ctx, ChannelPromise promise) throws Exception { fireCompleteEventIfNotAlready(ctx, CompleteReason.DISCONNECT); super.disconnect(ctx, promise); }
@Override public void channelInactive(ChannelHandlerContext ctx) throws Exception { fireCompleteEventIfNotAlready(ctx, CompleteReason.INACTIVE); super.channelInactive(ctx); }
@Override public void channelInactive(ChannelHandlerContext ctx) throws Exception { try { super.channelInactive(ctx); } finally { fireCompleteEventIfNotAlready(ctx, CompleteReason.INACTIVE); } }
@Override public void disconnect(ChannelHandlerContext ctx, ChannelPromise promise) throws Exception { fireCompleteEventIfNotAlready(ctx, CompleteReason.DISCONNECT); super.disconnect(ctx, promise); }
@Override public void deregister(ChannelHandlerContext ctx, ChannelPromise promise) throws Exception { fireCompleteEventIfNotAlready(ctx, CompleteReason.DEREGISTER); super.deregister(ctx, promise); }
@Override public void close(ChannelHandlerContext ctx, ChannelPromise promise) throws Exception { fireCompleteEventIfNotAlready(ctx, CompleteReason.CLOSE); super.close(ctx, promise); } }
@Override public void channelRead(ChannelHandlerContext ctx, Object msg) throws Exception { if (msg instanceof HttpResponse) { ctx.channel().attr(ATTR_HTTP_RESP).set((HttpResponse) msg); } try { super.channelRead(ctx, msg); } finally { if (msg instanceof LastHttpContent) { fireCompleteEventIfNotAlready(ctx, CompleteReason.SESSION_COMPLETE); } } }
@Override public void close(ChannelHandlerContext ctx, ChannelPromise promise) throws Exception { addPassportState(ctx, PassportState.SERVER_CH_CLOSE); fireCompleteEventIfNotAlready(ctx, CompleteReason.CLOSE); super.close(ctx, promise); }
fireCompleteEventIfNotAlready(ctx, CompleteReason.SESSION_COMPLETE); } else { promise.addListener(future -> { fireCompleteEventIfNotAlready(ctx, CompleteReason.SESSION_COMPLETE); });
@Override public void close(ChannelHandlerContext ctx, ChannelPromise promise) throws Exception { fireCompleteEventIfNotAlready(ctx, CompleteReason.CLOSE); super.close(ctx, promise); } }
@Override public void channelInactive(ChannelHandlerContext ctx) throws Exception { try { super.channelInactive(ctx); } finally { fireCompleteEventIfNotAlready(ctx, CompleteReason.INACTIVE); } }
@Override public void disconnect(ChannelHandlerContext ctx, ChannelPromise promise) throws Exception { fireCompleteEventIfNotAlready(ctx, CompleteReason.DISCONNECT); super.disconnect(ctx, promise); }
@Override public void deregister(ChannelHandlerContext ctx, ChannelPromise promise) throws Exception { fireCompleteEventIfNotAlready(ctx, CompleteReason.DEREGISTER); super.deregister(ctx, promise); }
@Override public void exceptionCaught(ChannelHandlerContext ctx, Throwable cause) throws Exception { super.exceptionCaught(ctx, cause); fireCompleteEventIfNotAlready(ctx, CompleteReason.EXCEPTION); }
@Override public void channelInactive(ChannelHandlerContext ctx) throws Exception { fireCompleteEventIfNotAlready(ctx, CompleteReason.INACTIVE); super.channelInactive(ctx); }
@Override public void disconnect(ChannelHandlerContext ctx, ChannelPromise promise) throws Exception { fireCompleteEventIfNotAlready(ctx, CompleteReason.DISCONNECT); super.disconnect(ctx, promise); }
@Override public void channelRead(ChannelHandlerContext ctx, Object msg) throws Exception { if (msg instanceof HttpResponse) { ctx.channel().attr(ATTR_HTTP_RESP).set((HttpResponse) msg); } try { super.channelRead(ctx, msg); } finally { if (msg instanceof LastHttpContent) { fireCompleteEventIfNotAlready(ctx, CompleteReason.SESSION_COMPLETE); } } }
@Override public void close(ChannelHandlerContext ctx, ChannelPromise promise) throws Exception { addPassportState(ctx, PassportState.SERVER_CH_CLOSE); fireCompleteEventIfNotAlready(ctx, CompleteReason.CLOSE); super.close(ctx, promise); }
fireCompleteEventIfNotAlready(ctx, CompleteReason.SESSION_COMPLETE); } else { promise.addListener(future -> { fireCompleteEventIfNotAlready(ctx, CompleteReason.SESSION_COMPLETE); });