在这里插入图片描述

报错信息:
Error starting ApplicationContext. To display the conditions report re-run your application with ‘debug’ enabled.
2020-05-15 00:05:12 ERROR [main]o.s.b.d.LoggingFailureAnalysisReporter [LoggingFailureAnalysisReporter.java : 40] -


APPLICATION FAILED TO START


Description:

A component required a bean of type ‘org.springframework.security.config.annotation.ObjectPostProcessor’ that could not be found.

Action:

Consider defining a bean of type ‘org.springframework.security.config.annotation.ObjectPostProcessor’ in your configuration.

解决:
启动类添加注解:

@EnableGlobalMethodSecurity(prePostEnabled = true)

在这里插入图片描述

Logo

为开发者提供学习成长、分享交流、生态实践、资源工具等服务,帮助开发者快速成长。

更多推荐