Error creating bean with name 'xx': Injection of autowired dependencies failed
2015-01-29 17:45
681 查看
Error creating bean with name 'stuMgrController': Injection of autowired dependencies failed; nested exception is org.springframework.beans.factory.BeanCreationException: Could
not autowire method: public void cc.svene.controller.StuMgrController.setStuMgrService(cc.svene.service.StuMgrService); nested exception is org.springframework.beans.factory.CannotLoadBeanClassException:
Error loading class [org.springframework.jdbc.datasource.DataSourceTransactionManager] for bean with name 'transactionManager' defined in URL [file:/D:/Program_Files/Develop/apache-tomcat-6.0.41/webapps/ssmdemo/WEB-INF/classes/spring-mybatis.xml]: problem
with class file or dependent class; nested exception is java.lang.NoClassDefFoundError: org/springframework/transaction/support/ResourceTransactionManager
解决方法:
不能注入:setStuMgrService(cc.svene.service.StuMgrService),
也就是StuMgrService没有被注入,所以要检查StuMgrService类有没有附上@Service的Service注解
或者是配置文件上的引用属性上的bean全限定类名不正确
not autowire method: public void cc.svene.controller.StuMgrController.setStuMgrService(cc.svene.service.StuMgrService); nested exception is org.springframework.beans.factory.CannotLoadBeanClassException:
Error loading class [org.springframework.jdbc.datasource.DataSourceTransactionManager] for bean with name 'transactionManager' defined in URL [file:/D:/Program_Files/Develop/apache-tomcat-6.0.41/webapps/ssmdemo/WEB-INF/classes/spring-mybatis.xml]: problem
with class file or dependent class; nested exception is java.lang.NoClassDefFoundError: org/springframework/transaction/support/ResourceTransactionManager
解决方法:
不能注入:setStuMgrService(cc.svene.service.StuMgrService),
也就是StuMgrService没有被注入,所以要检查StuMgrService类有没有附上@Service的Service注解
或者是配置文件上的引用属性上的bean全限定类名不正确
相关文章推荐
- Error creating bean with name 'XXX': Injection of autowired dependencies failed解决办法
- Error creating bean with name '****': Injection of autowired dependencies failed
- Java-4-解决报错:Error creating bean with name 'globalAppObj': Injection of autowired dependencies failed
- Error creating bean with name 'assetQueryController': Injection of autowired dependencies failed; ne
- Error creating bean with name 'userServiceImpl': Injection of autowired dependencies failed
- bean依赖注入错误:Error creating bean with name 'itemService': Injection of autowired dependencies failed
- Error creating bean with name 'xxxx': Injection of autowired dependencies failed;
- Error creating bean with name 'userServiceImpl': Injection of autowired dependencies failed
- Error creating bean with name '***(类名)': Injection of autowired dependencies failed;
- Error creating bean with name 'roleServiceImpl': Injection of autowired dependencies failed;
- Error creating bean with name 'adminUserController': Injection of autowired dependencies failed;
- Error creating bean with name 'contentTypeAdminController': Injection of autowired dependencies fail
- 【SPRINGMVC】Error creating bean with name 'projectController': Injection of autowired dependencies
- springMVC项目启动时出现bean注入失败的情况:Error creating bean with name 'XXX': Injection of autowired dependencies
- spring问题:Error creating bean with name 'articleController': Injection of autowired dependencies fail
- rror creating bean with name 'adminController': Injection of autowired dependencies failed;
- spring boot 报错 Error creating bean with name 'indexController': Injection of autowired dependencies
- Error creating bean with name 'menuController': Injection of autowired dependenc
- Error creating bean with name 'menuController': Injection of autowired dependency……
- Error creating bean with name 'menuController': Injection of autowired dependency……