首页 新闻 会员 周边 捐助

springboot+dubbo,使用xml配置时项目启动报错

0
[已关闭问题] 关闭于 2021-12-31 15:52

项目采用springboot+dubbo,xml文件配置dubbo,配置dubbo application时,该属性放在xml文件中,项目启动就报错,但是配置在application.yml中就能正常启动

报错如下:
Caused by: java.lang.IllegalStateException: Duplicate application configs: <dubbo:application name="xn-demo-provider" valid="true" id="xn-demo-provider" prefix="dubbo.application" /> and <dubbo:application valid="false" qosEnable="false" prefix="dubbo.application" />
at org.apache.dubbo.config.spring.ServiceBean.afterPropertiesSet(ServiceBean.java:157) ~[dubbo-2.7.0.jar:2.7.0]
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1863) ~[spring-beans-5.3.12.jar:5.3.12]
at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1800) ~[spring-beans-5.3.12.jar:5.3.12]
... 16 common frames omitted

二毛605332的主页 二毛605332 | 初学一级 | 园豆:181
提问于:2021-12-28 15:32
< >
分享
清除回答草稿
   您需要登录以后才能回答,未注册用户请先注册