@Test void exceptionCaughtSkippedWhenContextRemoved() { mockChannelHandlerContextChannelId(ctx, "abcedf"); final TestProbe<DssRestMasterActorCommand> testProbe = testKit.createTestProbe(); final DssRestHandler handler = newDssRestHandlerForTest(testProbe); handler.exceptionCaught(ctx, new NullPointerException()); assertTrue(true); }
@Override public void exceptionCaught(ChannelHandlerContext ctx, Throwable cause) { logger.error("exceptionCaught", cause); final String channelId = ctx.channel().id().asLongText(); if (Objects.isNull(channelHandlerContextMap.remove(channelId))) { return; } ctx.close(); }
DssRestHandler extends SimpleChannelInboundHandler<Object> implements DssHandler<DssRestChannelHandlerCommand> { @Override public void exceptionCaught(ChannelHandlerContext ctx, Throwable cause) { logger.error("exceptionCaught", cause); final String channelId = ctx.channel().id().asLongText(); if (Objects.isNull(channelHandlerContextMap.remove(channelId))) { return; } ctx.close(); } }
DssRestHandler extends SimpleChannelInboundHandler<Object> implements DssHandler<DssRestChannelHandlerCommand> { @Override public void exceptionCaught(ChannelHandlerContext ctx, Throwable cause) { logger.error("exceptionCaught", cause); final String channelId = ctx.channel().id().asLongText(); if (Objects.isNull(channelHandlerContextMap.remove(channelId))) { return; } ctx.close(); } DssRestHandler(
            ActorRef<DssRestChannelInitializerCommand> restChannelInitializerActor,
            ActorRef<DssRestMasterActorCommand> restMasterActorRef,
            String name); }
DssRestHandler extends SimpleChannelInboundHandler<Object> implements DssHandler<DssRestChannelHandlerCommand> { @Override public void exceptionCaught(ChannelHandlerContext ctx, Throwable cause) { logger.error("exceptionCaught", cause); final String channelId = ctx.channel().id().asLongText(); if (Objects.isNull(channelHandlerContextMap.remove(channelId))) { return; } ctx.close(); } DssRestHandler(
            ActorRef<DssRestChannelInitializerCommand> restChannelInitializerActor,
            ActorRef<DssRestMasterActorCommand> restMasterActorRef,
            String name); @Override void channelReadComplete(ChannelHandlerContext ctx); @Override void exceptionCaught(ChannelHandlerContext ctx, Throwable cause); @Override void channelUnregistered(ChannelHandlerContext ctx); @Override Behavior<DssRestChannelHandlerCommand> create(); }
DssRestHandler extends SimpleChannelInboundHandler<Object> implements DssHandler<DssRestChannelHandlerCommand> { @Override public void exceptionCaught(ChannelHandlerContext ctx, Throwable cause) { logger.error("exceptionCaught", cause); final String channelId = ctx.channel().id().asLongText(); if (Objects.isNull(channelHandlerContextMap.remove(channelId))) { return; } ctx.close(); } DssRestHandler(
            ActorRef<DssRestChannelInitializerCommand> restChannelInitializerActor,
            ActorRef<DssRestMasterActorCommand> restMasterActorRef,
            String name); @Override void channelReadComplete(ChannelHandlerContext ctx); @Override void exceptionCaught(ChannelHandlerContext ctx, Throwable cause); @Override void channelUnregistered(ChannelHandlerContext ctx); @Override Behavior<DssRestChannelHandlerCommand> create();  }