简体   繁体   English

Spring 云网关带断路器

[英]Spring Cloud Gateway with CircuitBreaker

I am getting following exception while starting Gateway spring boot Application启动网关 spring 启动应用程序时出现以下异常

ava.lang.IllegalArgumentException: Unable to find GatewayFilterFactory with name CircuitBreaker ava.lang.IllegalArgumentException:找不到名称为 CircuitBreaker 的 GatewayFilterFactory

filter configuration is filters: - name: CircuitBreaker args: name: MicroService fallback: forward:/fallbackurl过滤器配置为过滤器:-名称:CircuitBreaker 参数:名称:微服务回退:转发:/fallbackurl

Does any one has idea how can this be fixed.有谁知道如何解决这个问题。 `` ``

I was getting the same error.我遇到了同样的错误。 I tried adding the dependency:我尝试添加依赖项:

<dependency>
  <groupId>org.springframework.cloud</groupId>
  <artifactId>spring-cloud-starter-circuitbreaker-reactor-resilience4j</artifactId>
</dependency>

I already added netflix-hystrix but it was giving the same error.我已经添加了 netflix-hystrix,但它给出了同样的错误。

<dependency>
  <groupId>org.springframework.cloud</groupId>
  <artifactId>spring-cloud-starter-netflix-hystrix</artifactId>
  <version>2.2.9.RELEASE</version>
</dependency>

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM