wenshana 2021-01-19 15:47 采纳率: 100%
浏览 99
已采纳

springboot启动报错怎么解决呀

以下是全部信息

Error starting ApplicationContext. To display the auto-configuration report re-run your application with 'debug' enabled.
2021-01-19 15:43:41.558 -ERROR 16884 --- [main] o.s.boot.SpringApplication               : Application startup failed

org.springframework.beans.factory.BeanDefinitionStoreException: Failed to process import candidates for configuration class [com.haojiankang.fdmw.hadapi.FdmwHadapiApplication]; nested exception is org.springframework.context.annotation.ConflictingBeanDefinitionException: Annotation-specified bean name 'sysmgrConfigBean' for bean class [com.haojiankang.lion.sysmgr.service.impl.SharpConfigServiceImpl] conflicts with existing, non-compatible bean definition of same name and class [com.haojiankang.fdmw.hadapi.config.SharpConfigServiceImpl]
    at org.springframework.context.annotation.ConfigurationClassParser.processImports(ConfigurationClassParser.java:621) ~[spring-context-4.3.17.RELEASE.jar:4.3.17.RELEASE]
    at org.springframework.context.annotation.ConfigurationClassParser.processDeferredImportSelectors(ConfigurationClassParser.java:553) ~[spring-context-4.3.17.RELEASE.jar:4.3.17.RELEASE]
    at org.springframework.context.annotation.ConfigurationClassParser.parse(ConfigurationClassParser.java:187) ~[spring-context-4.3.17.RELEASE.jar:4.3.17.RELEASE]
    at org.springframework.context.annotation.ConfigurationClassPostProcessor.processConfigBeanDefinitions(ConfigurationClassPostProcessor.java:308) ~[spring-context-4.3.17.RELEASE.jar:4.3.17.RELEASE]
    at org.springframework.context.annotation.ConfigurationClassPostProcessor.postProcessBeanDefinitionRegistry(ConfigurationClassPostProcessor.java:228) ~[spring-context-4.3.17.RELEASE.jar:4.3.17.RELEASE]
    at org.springframework.context.support.PostProcessorRegistrationDelegate.invokeBeanDefinitionRegistryPostProcessors(PostProcessorRegistrationDelegate.java:272) ~[spring-context-4.3.17.RELEASE.jar:4.3.17.RELEASE]
    at org.springframework.context.support.PostProcessorRegistrationDelegate.invokeBeanFactoryPostProcessors(PostProcessorRegistrationDelegate.java:92) ~[spring-context-4.3.17.RELEASE.jar:4.3.17.RELEASE]
    at org.springframework.context.support.AbstractApplicationContext.invokeBeanFactoryPostProcessors(AbstractApplicationContext.java:687) ~[spring-context-4.3.17.RELEASE.jar:4.3.17.RELEASE]
    at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:525) ~[spring-context-4.3.17.RELEASE.jar:4.3.17.RELEASE]
    at org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.refresh(EmbeddedWebApplicationContext.java:122) ~[spring-boot-1.5.13.RELEASE.jar:1.5.13.RELEASE]
    at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:693) [spring-boot-1.5.13.RELEASE.jar:1.5.13.RELEASE]
    at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:360) [spring-boot-1.5.13.RELEASE.jar:1.5.13.RELEASE]
    at org.springframework.boot.SpringApplication.run(SpringApplication.java:303) [spring-boot-1.5.13.RELEASE.jar:1.5.13.RELEASE]
    at org.springframework.boot.SpringApplication.run(SpringApplication.java:1118) [spring-boot-1.5.13.RELEASE.jar:1.5.13.RELEASE]
    at org.springframework.boot.SpringApplication.run(SpringApplication.java:1107) [spring-boot-1.5.13.RELEASE.jar:1.5.13.RELEASE]
    at com.haojiankang.fdmw.hadapi.FdmwHadapiApplication.main(FdmwHadapiApplication.java:46) [classes/:na]
Caused by: org.springframework.context.annotation.ConflictingBeanDefinitionException: Annotation-specified bean name 'sysmgrConfigBean' for bean class [com.haojiankang.lion.sysmgr.service.impl.SharpConfigServiceImpl] conflicts with existing, non-compatible bean definition of same name and class [com.haojiankang.fdmw.hadapi.config.SharpConfigServiceImpl]
    at org.springframework.context.annotation.ClassPathBeanDefinitionScanner.checkCandidate(ClassPathBeanDefinitionScanner.java:345) ~[spring-context-4.3.17.RELEASE.jar:4.3.17.RELEASE]
    at org.springframework.context.annotation.ClassPathBeanDefinitionScanner.doScan(ClassPathBeanDefinitionScanner.java:283) ~[spring-context-4.3.17.RELEASE.jar:4.3.17.RELEASE]
    at org.springframework.context.annotation.ComponentScanAnnotationParser.parse(ComponentScanAnnotationParser.java:135) ~[spring-context-4.3.17.RELEASE.jar:4.3.17.RELEASE]
    at org.springframework.context.annotation.ConfigurationClassParser.doProcessConfigurationClass(ConfigurationClassParser.java:289) ~[spring-context-4.3.17.RELEASE.jar:4.3.17.RELEASE]
    at org.springframework.context.annotation.ConfigurationClassParser.processConfigurationClass(ConfigurationClassParser.java:247) ~[spring-context-4.3.17.RELEASE.jar:4.3.17.RELEASE]
    at org.springframework.context.annotation.ConfigurationClassParser.processImports(ConfigurationClassParser.java:611) ~[spring-context-4.3.17.RELEASE.jar:4.3.17.RELEASE]
    ... 15 common frames omitted

Disconnected from the target VM, address: '127.0.0.1:59032', transport: 'socket'

Process finished with exit code 1

  • 写回答

2条回答 默认 最新

  • Random17 2021-01-19 15:50
    关注

     [com.haojiankang.lion.sysmgr.service.impl.SharpConfigServiceImpl] conflicts with existing, non-compatible bean definition of same name and class [com.haojiankang.fdmw.hadapi.config.SharpConfigServiceImpl]

     

    bean 的名称重复

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论
查看更多回答(1条)

报告相同问题?

悬赏问题

  • ¥35 用python实现除法算法中goldschmidt算法
  • ¥15 汇编代码转换成C代码
  • ¥15 除法算法中的归一化具体是怎么变的?
  • ¥20 集成电路的逻辑电路和晶体管简化图
  • ¥15 下载windows builder后的问题
  • ¥15 按要求对程序的逻辑进行更正
  • ¥50 悬赏帮写C++编程 诚信
  • ¥15 端口连接数为什么会有限制
  • ¥15 安卓数据提交之后格式不对
  • ¥15 需要数据库运行的图片