大聪明397
2021-06-03 17:38
采纳率: 100%
浏览 196
已结题

求助:IDEA2021.1运行springboot项目报错

第一个是tomcat启动报错:org.springframework.boot.web.embedded.tomcat.TomcatStarter","method_name":"onStartup","code_line":61,"message":"Error starting Tomcat context. Exception: org.springframework.beans.factory.UnsatisfiedDependencyException. Message: Error creating bean with name 'getUserFilter' defined in class path resource [com/weimob/test/performance/config/FilterConfig.class]: Unsatisfied dependency expressed through method 'getUserFilter' parameter 0; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'authorizationService': Unsatisfied dependency expressed through field 'userDao'; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'userDao': Unsatisfied dependency expressed through field 'baseMapper'; nested exception is org.springframework.beans.factory.NoSuchBeanDefinitionException: No qualifying bean of type 'com.weimob.test.performance.mapper.base.BaseMapper<com.weimob.test.performance.entity.Users>' available: expected at least 1 bean which qualifies as autowire candidate. Dependency annotations: {@org.springframework.beans.factory.annotation.Autowired(required=true)}"}
第二个是:

org.springframework.boot.diagnostics.LoggingFailureAnalysisReporter","method_name":"report","code_line":40,"message":"\r\n\r\n***************************\r\nAPPLICATION FAILED TO START\r\n***************************\r\n\r\nDescription:\r\n\r\nField baseMapper in com.weimob.test.performance.dao.base.BaseDao required a bean of type 'com.weimob.test.performance.mapper.base.BaseMapper' that could not be found.\r\n\r\n\r\nAction:\r\n\r\nConsider defining a bean of type 'com.weimob.test.performance.mapper.base.BaseMapper' in your configuration.\r\n"}
 

  • 收藏

3条回答 默认 最新

  • Bosen的技术分享栈 2021-06-03 17:42
    已采纳

    你的UserDao有没有加上spring的注解?

    打赏 评论
  • 大聪明397 2021-06-03 18:30

    https://ask.csdn.net/questions/7440698?spm=1001.2014.3001.5501

    感觉和这个问题有关,求助各位大佬

    打赏 评论
  • 昵称不好取a 2021-06-04 01:37

    最后把其他文件一起粘贴上来

     

    打赏 评论

相关推荐 更多相似问题