admin管理员组

文章数量:1567555

3.报错Consider renaming one of the beans or enabling overriding by setting spring.main.allow-bean-definition-overriding=true

***************************
APPLICATION FAILED TO START
***************************

Description:

The bean 'sentinelGatewayFilter', defined in class path resource [com/alibaba/cloud/sentinel/gateway/scg/SentinelSCGAutoConfiguration.class], could not be registered. A bean with that name has already been defined in class path resource [com/hjt/config/GatewayConfig.class] and overriding is disabled.

Action:

Consider renaming one of the beans or enabling overriding by setting spring.main.allow-bean-definition-overriding=true

问题分析:就是出现bean名字相同不能重复注册

解决方案:

spring
   main:
     allow-bean-definition-overriding: true

本文标签: enablingoverridingrenamingbeansSetting