【问题标题】:Hystrix Configuration clarification: metrics.rollingStats.timeInMillisecondsHystrix 配置说明:metrics.rollingStats.timeInMilliseconds
【发布时间】:2019-01-02 21:50:27
【问题描述】:

我正在尝试了解 metrics.rollingStats.timeInMilliseconds 和 metrics.rollingStats.numBuckets 如何协同工作。

如果我有以下配置:

circuitBreaker.requestVolumeThreshold=20
circuitBreaker.errorThresholdPercentage=50
metrics.rollingStats.timeInMilliseconds=10000
metrics.rollingStats.numBuckets=10

对我来说,这意味着: 1) 在做出决定之前,我需要在我的窗口中至少提出 20 个请求 2) 需要 50% 以上的请求失败才能打开断路器

但是桶的数量是如何起作用的呢?每个桶的 requestVolumeThreshHold 和错误阈值是多少?我试图了解是否/如何使用水桶来确定断路器跳闸。

【问题讨论】:

    标签: hystrix


    【解决方案1】:

    我能够通过创建一个测试断路器的简单应用来回答我自己的问题。

    确定何时打开电路的公式使用请求量阈值,在整个滚动统计 timeInMilliseconds 窗口期间的错误阈值百分比。存储桶仅用于更新滚动窗口的方式/时间。

    【讨论】:

      猜你喜欢
      • 2016-11-26
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2013-07-27
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多