最近在做dubbo项目,今天升级了下dubbo的版本,然后就掉坑里去了,选择版本很重要啊啊啊......
错误描述:
java.lang.NoClassDefFoundError: io/netty/channel/nio/NioEventLoopGroup
at com.alibaba.dubbo.qos.server.Server.start(Server.java:84)
at com.alibaba.dubbo.qos.protocol.QosProtocolWrapper.startQosServer(QosProtocolWrapper.java:99)
at com.alibaba.dubbo.qos.protocol.QosProtocolWrapper.export(QosProtocolWrapper.java:59)
at com.alibaba.dubbo.rpc.protocol.ProtocolFilterWrapper.export(ProtocolFilterWrapper.java:98)
at com.alibaba.dubbo.rpc.protocol.ProtocolListenerWrapper.export(ProtocolListenerWrapper.java:55)
at com.alibaba.dubbo.rpc.Protocol$Adaptive.export(Protocol$Adaptive.java)
at com.alibaba.dubbo.config.ServiceConfig.doExportUrlsFor1Protocol(ServiceConfig.java:515)
at com.alibaba.dubbo.config.ServiceConfig.doExportUrls(ServiceConfig.java:360)
at com.alibaba.dubbo.config.ServiceConfig.doExport(ServiceConfig.java:319)
at com.alibaba.dubbo.config.ServiceConfig.export(ServiceConfig.java:217)
at com.alibaba.dubbo.config.spring.ServiceBean.export(ServiceBean.java:266)
at com.alibaba.dubbo.config.spring.ServiceBean.onApplicationEvent(ServiceBean.java:106)
at com.alibaba.dubbo.config.spring.ServiceBean.onApplicationEvent(ServiceBean.java:53)
报错大概的意思是我dubbo版本升级后,缺少依赖,看了下资料,添加依赖就解决了:
<dependency> <groupId>io.netty</groupId> <artifactId>netty-all</artifactId> <version>4.1.32.Final</version> </dependency>
来源:CSDN
作者:徐卖狼
链接:https://blog.csdn.net/CoreyXuu/article/details/88975349