【发布时间】:2023-02-22 23:09:13
【问题描述】:
在 resilience4j 配置中,我同时具有断路器、隔板和线程超时的参数。一旦发生回退,我就无法找出导致回退的原因。我正在骆驼路线中实施resilience4j配置。
【问题讨论】:
标签: apache-camel
在 resilience4j 配置中,我同时具有断路器、隔板和线程超时的参数。一旦发生回退,我就无法找出导致回退的原因。我正在骆驼路线中实施resilience4j配置。
【问题讨论】:
标签: apache-camel
你不能混合 onFallback 和 Exception,使用 story() 和 throwException WhenHalfOpenOrOpenState(true) 配置:
.doTry()
.circuitBreaker()
.resilience4jConfiguration()
.throwExceptionWhenHalfOpenOrOpenState(true)
.end()
.to("http://fooservice.com/faulty")
.end()
.endDoTry()
.doCatch(Exception.class)
.log("${exception.message}")
.end
【讨论】: