Istio断路器是谁跳闸的? [英] Istio Circuit Breaker who trips it?

查看:71
本文介绍了Istio断路器是谁跳闸的?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我目前正在研究1.6版中的服务网格Istio.数据平面(Envoy代理)由受控平面配置.

I am currently doing research on the service mesh Istio in version 1.6. The data plane (Envoy proxies) are configured by the controle plane.

  1. 当我通过创建目标规则配置断路器并且断路器打开时,客户端sidecar代理是否已经返回503或服务器端sidecar代理?
  2. 客户端Sidecar代理是自动将请求路由到服务的另一个可用实例,还是只是将503返回到应用程序容器?

提前谢谢!

推荐答案

  1. 在日志条目中,您可以检查它们以找出断路器停止的连接的两端. istio-proxy容器的日志消息中显示了连接双方的IP地址.
  1. In the log entries, you can inspect them to figure out both end of the connection that was stopped by the circuit breaker. IP addresses of both sides of the connection are present in the log message from the istio-proxy container.

  {
  insertId: "..."
  labels: {
    k8s-pod/app: "circuitbreaker-jdwa8424"
    k8s-pod/pod-template-hash: "..."
  }
  logName: ".../logs/stdout"
  receiveTimestamp: "2020-06-09T05:59:30.209882320Z"
  resource: {
    labels: {
      cluster_name: "..."
      container_name: "istio-proxy"
      location: "..."
      namespace_name: "circuit"
      pod_name: "circuit-service-a31cb334d-66qeq"
      project_id: "..."
    }
    type: "k8s_container"
  }
  severity: "INFO"
  textPayload: "[2020-06-09T05:59:27.854Z] UO 0 0 0 "-" - - 172.207.3.243:443 10.1.13.216:36774 "
  timestamp: "2020-06-09TT05:59:28.071001549Z"
  }

消息来自istio-proxy容器,该容器运行受请求发送到的CircuitBreaker策略影响的Envoy.还有被中断的连接的源和目标的IP地址.

The message is coming from istio-proxy container which runs Envoy that was affected by CircuitBreaker policy that request was sent to. Also there is the IP address of both the source and destination of the connection that was interrupted.

  1. 它将返回503.可以配置重试,但是我没有测试它与CircuitBreaker的协同作用,并且如果前一个返回错误,则重试实际上是否将转到其他pod.
  1. It will return 503. There is option to configure retries, however I did not test its synergy with CircuitBreaker and if the retry actually will go to different pod if previous returned an error.

还查看了有关 CircuitBreaker 的最详细的解释找到.

Also take a look at the most detailed explanation of CircuitBreaker I managed to find.

希望有帮助.

这篇关于Istio断路器是谁跳闸的?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆