这是当前的Jmx 导出器模式:
pattern: 'metrics<name=resilience4jCircuitbreakerState.name.(.*).state.(.*), type=gauges><>Value'
name: 'x.y.z.resilience4j.circuitbreaker.state'
labels: {name: "$1", kind: "$2" }
type: GAUGE
电流输出:
x_y_z_resilience4j_circuitbreaker_state{kind="open",name="a",} 0.0
x_y_z__resilience4j_circuitbreaker_state{kind="closed",name="b",} 1.0
x_y_z__resilience4j_circuitbreaker_state{kind="half_open",name="c",} 0.0
x_y_z__resilience4j_circuitbreaker_state{kind="half_open",name="d",} 0.0
x_y_z__resilience4j_circuitbreaker_state{kind="forced_open",name="e",} 0.0
x_y_z__resilience4j_circuitbreaker_state{kind="disabled",name="f",} 0.0
x_y_z__resilience4j_circuitbreaker_state{kind="disabled",name="g",} 0.0
x_y_z__resilience4j_circuitbreaker_state{kind="forced_open",name="h",} 0.0
x_y_z__resilience4j_circuitbreaker_state{kind="closed",name="i",} 1.0
x_y_z__resilience4j_circuitbreaker_state{kind="closed",name="j",} 1.0
这实际上工作正常。但是为了提高基数,我们决定不公开修改 Yml 的 0.0 值(如果有的话)。
上述样本的预期输出是,
x_y_z__resilience4j_circuitbreaker_state{kind="closed",name="b",} 1.0
x_y_z__resilience4j_circuitbreaker_state{kind="closed",name="i",} 1.0
x_y_z__resilience4j_circuitbreaker_state{kind="closed",name="j",} 1.0
请随时在下面发表评论。