NettyTcpClientInboundHandler.java 615 B

1234567891011121314151617181920
  1. package com.its.api.xnettcp.client.handler;
  2. import io.netty.channel.ChannelHandlerContext;
  3. import io.netty.channel.SimpleChannelInboundHandler;
  4. import lombok.extern.slf4j.Slf4j;
  5. @Slf4j
  6. public class NettyTcpClientInboundHandler extends SimpleChannelInboundHandler<Object> {
  7. @Override
  8. protected void channelRead0(ChannelHandlerContext channelHandlerContext, Object msg) throws Exception {
  9. }
  10. public void exceptionCaught(ChannelHandlerContext ctx, Throwable cause) throws Exception
  11. {
  12. log.error("exceptionCaught: {}", ctx.toString());
  13. super.exceptionCaught(ctx, cause);
  14. }
  15. }