spring - 无法注册在类路径资源 [org/activiti/spring/boot/MethodSecurityConfig.class] 中定义的 bean 'methodSecurityInterceptor'
问题描述
***************************
APPLICATION FAILED TO START
***************************
Description:
The bean 'methodSecurityInterceptor', defined in class path resource [org/activiti/spring/boot/MethodSecurityConfig.class], could not be registered. A bean with that name has already been defined in class path resource [org/springframework/security/config/annotation/method/configuration/GlobalMethodSecurityConfiguration.class] and overriding is disabled.
Action:
Consider renaming one of the beans or enabling overriding by setting spring.main.allow-bean-definition-overriding=true
我使用 SpringBoot 2.2.12 和 SpringSecurity 5.2.8 和 activiti 7.1.0.M4 然后得到错误。
我认为这可能是由与 SpringSecurity 的 activiti 冲突引起的。
解决方案
我认为。如果两个框架bean命名定义有冲突,可以尝试自定义其中一个
推荐阅读
- c++ - 为什么这个 .c 文件只有一行“../xx/xx.c”?
- c# - 在程序集中找不到上下文类型 - 类型“ApplicationDbContext”不继承自 DbContext
- javascript - 这:对多个对象执行相同的代码
- phpunit - 在 PhpUnit 中的 tearDown() 中真正应该做什么
- javascript - 在以随机顺序删除集合后,使用 jvenn 更新 Venn
- php - Laravel 6.0 购物车包:缺少 [Route: cart.update] [URI: {rowId}] 所需的参数
- kubernetes - Helm 3.0.2 试运行 + stable/prometheus-operator?这应该工作吗?
- regression - 使用 mvtnorm 包构建我自己的多项概率模型
- c# - Nlog 在 Dotnetty 处理程序中无法正常工作
- javascript - 未定义的结果 foreach 数组 javascript