为了账号安全,请及时绑定邮箱和手机立即绑定

HomepageUserServiceTest无法通过测试

Caused by: org.springframework.beans.factory.support.BeanDefinitionOverrideException: Invalid bean definition with name 'eureka-client-homepage-course.FeignClientSpecification' defined in null: Cannot register bean definition [Generic bean: class [org.springframework.cloud.openfeign.FeignClientSpecification]; scope=; abstract=false; lazyInit=false; autowireMode=0; dependencyCheck=0; autowireCandidate=true; primary=false; factoryBeanName=null; factoryMethodName=null; initMethodName=null; destroyMethodName=null] for bean 'eureka-client-homepage-course.FeignClientSpecification': There is already [Generic bean: class [org.springframework.cloud.openfeign.FeignClientSpecification]; scope=; abstract=false; lazyInit=false; autowireMode=0; dependencyCheck=0; autowireCandidate=true; primary=false; factoryBeanName=null; factoryMethodName=null; initMethodName=null; destroyMethodName=null] bound.


已经删除掉了yml中的

feign:
#  hystrix:
#    enabled: true


正在回答

1 回答

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

完美解决

0 回复 有任何疑惑可以回复我~

举报

0/150
提交
取消

HomepageUserServiceTest无法通过测试

我要回答 关注问题
意见反馈 帮助中心 APP下载
官方微信