今天写项目过程中出现A模块调用B模块,A,B模块都有Feign调用,其中一个模块启动报错:The bean 'service-resource.FeignClientSpecification' could not be registered、A bean with that name has already been defined and overriding is disabled.
原因:
A模块和B模块存在FeignClient配置相同,冲突:
解决:
报错那个模块配置application.yml配置:
spring.main.allow-bean-definition-overriding: true