本地搭建spring-boot集成dubbo问题汇总
1,java.lang.NoClassDefFoundError: com/alibaba/spring/util/PropertySourcesUtils
<dependency> <groupId>com.alibaba.spring</groupId> <artifactId>spring-context-support</artifactId> <version>1.0.2</version> </dependency>
2,
原因是:新建的包没有在项目里面,全部挪到项目里面就好了
3,inconsistent stack height Index -1 out of bounds for length 4
duoob的service的方法名最好不要用getOrders这种以get...开头,有可能启动报错: 修改所有的方法不是以get开头
另外我用的dubbo版本2.6.5 spring-boot版本2.7.14
4,java.lang.NoClassDefFoundError: org/apache/curator/framework/CuratorFrameworkFactory
<dependency> <groupId>org.apache.curator</groupId> <artifactId>curator-framework</artifactId> <version>2.8.0</version> </dependency> <dependency> <groupId>org.apache.curator</groupId> <artifactId>curator-recipes</artifactId> <version>2.8.0</version> </dependency>
5,本地启动一闪而过,原因是缺乏依赖包spring-boot-starter-web
<dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-web</artifactId> </dependency>
本文来自博客园,作者:春江潮水连海平,转载请注明原文链接:https://www.cnblogs.com/alonewaiting/p/17632716.html