org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'homeController': Injection of autowired dependencies failed; nested exception is org.springframework.beans.factory.BeanCreationException: Could not autowire field: private lab.service.LabService lab.controller.HomeController.labservice; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'lab.service.LabServiceImpl#0': Injection of autowired dependencies failed; nested exception is org.springframework.beans.factory.BeanCreationException: Could not autowire field: private lab.dao.ActivityDaoImpl lab.service.LabServiceImpl.activityDao; nested exception is org.springframework.beans.factory.NoSuchBeanDefinitionException: No qualifying bean of type [lab.dao.ActivityDaoImpl] found for dependency: expected at least 1 bean which qualifies as autowire candidate for this dependency. Dependency annotations: {@org.springframework.beans.factory.annotation.Autowired(required=true)}
Searched on Google with the first line of a JAVA stack trace?
We can recommend more relevant solutions and speed up debugging when you paste your entire stack trace with the exception message. Try a sample exception.
Recommended solutions based on your search
Samebug tips
Add guice to the dependencies.
libraryDependencies += guice
Check Servers Launch Configuration in Eclipse. See the details below.
Solutions on the web
via segmentfault.com by Unknown author, 2 years ago
via segmentfault.com by Unknown author, 2 years ago
via Stack Overflow by stackUser2000
, 2 years agovia Stack Overflow by user1298486
, 2 years agovia Stack Overflow by masterdany88
, 2 years agovia soso.io by Unknown author, 2 years ago
org.springframework.beans.factory.BeanCreationException: Could not autowire field: private lab.service.LabService lab.controller.HomeController.labservice; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'lab.service.LabServiceImpl#0': Injection of autowired dependencies failed; nested exception is org.springframework.beans.factory.BeanCreationException: Could not autowire field: private lab.dao.ActivityDaoImpl lab.service.LabServiceImpl.activityDao; nested exception is org.springframework.beans.factory.NoSuchBeanDefinitionException: No qualifying bean of type [lab.dao.ActivityDaoImpl] found for dependency: expected at least 1 bean which qualifies as autowire candidate for this dependency. Dependency annotations: {@org.springframework.beans.factory.annotation.Autowired(required=true)}
at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor$AutowiredFieldElement.inject(AutowiredAnnotationBeanPostProcessor.java:561)
at org.springframework.beans.factory.annotation.InjectionMetadata.inject(InjectionMetadata.java:88)
at org.springframework.beans.factory.annotation.AutowiredAnnotationBeanPostProcessor.postProcessPropertyValues(AutowiredAnnotationBeanPostProcessor.java:331)