Error starting ApplicationContext. To display the conditions report re-run your application with 'debug' enabled.
2020-11-30 17:38:00.450 ERROR 24472 --- [ main] o.s.b.d.LoggingFailureAnalysisReporter :
***************************
APPLICATION FAILED TO START
***************************
Description:
Field studentService in com.gxuwz.ckf.controller.UserController required a bean of type 'com.gxuwz.ckf.service.StudentService' that could not be found.
The injection point has the following annotations:
- @org.springframework.beans.factory.annotation.Autowired(required=true)
Action:
Consider defining a bean of type 'com.gxuwz.ckf.service.StudentService' in your configuration.
原因:
忘了加注解


在尝试启动Spring Boot应用时遇到了错误,应用程序无法启动。问题源于UserController中@Autowired注解的StudentService字段找不到对应的bean。解决方案是检查配置,确保已经定义了StudentService的bean。这是一个常见的Spring依赖注入问题。
1176

被折叠的 条评论
为什么被折叠?



