Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

No qualifying bean of type 'it.ozimov.springboot.mail.service.EmailService' available #48

Closed
ostenant opened this issue Apr 5, 2017 · 3 comments

Comments

@ostenant
Copy link

ostenant commented Apr 5, 2017

WARN 6496 --- [ main] ationConfigEmbeddedWebApplicationContext : Exception encountered during context initialization - cancelling refresh attempt: org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'simpleMimeEmailWithThymeleafApplication': Unsatisfied dependency expressed through field 'simpleThymeleafEmailService'; nested exception is org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name 'simpleThymeleafEmailService': Unsatisfied dependency expressed through field 'emailService'; nested exception is org.springframework.beans.factory.NoSuchBeanDefinitionException: No qualifying bean of type 'it.ozimov.springboot.mail.service.EmailService' available: expected at least 1 bean which qualifies as autowire candidate. Dependency annotations: {@org.springframework.beans.factory.annotation.Autowired(required=true)}

@robertotru
Copy link
Member

Hi,
Generally speaking, trying to understand what goes wrong without knowing the version that bring the error and without having a look at the configuration of the main class and at the application.properties it's really complex.

In this case, I would suggest to have a look at the examples folder. There is an example that shows you how to autowire the service been

@ostenant
Copy link
Author

ostenant commented Apr 5, 2017 via email

@robertotru
Copy link
Member

Super! I'll close the issue then!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants