zoukankan      html  css  js  c++  java
  • Exception in thread "Thread-5" java.lang.NoSuchMethodError: io.netty.util.concurrent.SingleThreadEventExecutor异常处理

    异常
    Exception in thread "Thread-5" java.lang.NoSuchMethodError: io.netty.util.concurrent.SingleThreadEventExecutor.(Lio/netty/util/concurrent/EventExecutorGroup;Ljava/util/concurrent/Executor;ZLjava/util/Queue;Lio/netty/util/concurrent/RejectedExecutionHandler;)V
    at io.netty.channel.SingleThreadEventLoop.(SingleThreadEventLoop.java:65)
    at io.netty.channel.nio.NioEventLoop.(NioEventLoop.java:138)
    at io.netty.channel.nio.NioEventLoopGroup.newChild(NioEventLoopGroup.java:146)
    at io.netty.channel.nio.NioEventLoopGroup.newChild(NioEventLoopGroup.java:37)
    at io.netty.util.concurrent.MultithreadEventExecutorGroup.(MultithreadEventExecutorGroup.java:84)
    at io.netty.util.concurrent.MultithreadEventExecutorGroup.(MultithreadEventExecutorGroup.java:58)
    at io.netty.channel.MultithreadEventLoopGroup.(MultithreadEventLoopGroup.java:52)
    at io.netty.channel.nio.NioEventLoopGroup.(NioEventLoopGroup.java:96)
    at io.netty.channel.nio.NioEventLoopGroup.(NioEventLoopGroup.java:91)
    at io.netty.channel.nio.NioEventLoopGroup.(NioEventLoopGroup.java:72)
    at io.netty.channel.nio.NioEventLoopGroup.(NioEventLoopGroup.java:52)
    at io.netty.channel.nio.NioEventLoopGroup.(NioEventLoopGroup.java:44)
    at com.diesheng.wehat.websocket.NettyServer.startServer(NettyServer.java:39)
    at com.diesheng.wehat.websocket.NettyServer.access$000(NettyServer.java:22)
    at com.diesheng.wehat.websocket.NettyServer$2.run(NettyServer.java:77)
    at java.lang.Thread.run(Thread.java:748)

    由于单独引用netty版本 在tomcat启动时 出现以上的异常信息 经过搜索 了解问题如下
    由于io.lettuce:lettuce-core:jar:5.1.7.RELEASE中引用了其他版本的netty 导致了netty 启动冲突

    解决方案



    org.springframework.boot
    spring-boot-starter-data-redis


    io.netty
    netty-common


    io.netty
    netty-handler


    io.netty
    netty-transport


      再次 使用mvn dependency:tree 查看maven 树
      ![](https://img2020.cnblogs.com/blog/883541/202005/883541-20200519094852830-1835802717.png)

        吾之爱,心之念。
               携子手,到白头。

  • 相关阅读:
    redis单机安装以及简单redis集群搭建
    Linux中JDK安装教程
    微信公众号开发(一)
    easyui多图片上传+预览切换+支持IE8
    mybatis动态sql之foreach标签
    java List递归排序,传统方式和java8 Stream优化递归,无序的列表按照父级关系进行排序(两种排序类型)
    java钉钉通讯录同步
    java使用poi生成导出Excel(新)
    java 图片转base64字符串、base64字符串转图片
    Spring事务mysql不回滚:mysql引擎修改
  • 原文地址:https://www.cnblogs.com/JC-0527/p/12915170.html
Copyright © 2011-2022 走看看