报错信息如下
Unsatisfied dependency expressed through field 'userManagerService';
nested exception is org.springframework.beans.factory.NoSuchBeanDefinitionException:
No qualifying bean of type 'dubbo.exercise.one.basic.user.service.UserManagerService' available:
expected at least 1 bean which qualifies as autowire candidate.
Dependency annotations: {@org.springframework.beans.factory.annotation.Autowired(required=true)}
在 Spring boot 的官网中有这样一段内容
We generally recommend that you locate your main application class in a root package above other classes. The @SpringBootApplication annotation is often placed on your main class, and it implicitly defines a base “search package” for certain items.
Spring Boot 项目在启动的时候是从启动类所在的包路径开始扫描相关类
接下来看看我们的项目结构