Resilience4J + TimeLimiter + Bulkhead #2159
keshoresiva
started this conversation in
General
Replies: 1 comment
-
CompletableFuture cannot be canceled. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hello.. I am trying to implement R4j with timelimiter. When my main method takes more time.. fallback is getting executed. In this approach, is the future thread getting cancelled as it took more time ..? I am using java 11. Please advice.
i am having below property
resilice4j.timelimiter.configs.tl.cancel-running-future=true
resilice4j.timelimiter.configs.tl.timeout-duration=10ms
@bulkhead(name="bh", type=Bulkhead.Type.THREAPOOL)
@Timelimiter(name="tl", fallbackMethod="fixissue")
@CircuitBraker(name="cb", fallbackMethod="fixissue")
public CompletableFuture<List> getItem(){
// biz logic and calls to db
}
public CompletableFuture<Llist fixissue(Throwable t) {
}
Beta Was this translation helpful? Give feedback.
All reactions