[resilience4j-ratpack] Documentation is misleading, incomplete, or invalid
See original GitHub issueWhile attempting to implement the resilience4j-ratpack package into my ratpack application, I am encountering a few issues regarding the documentation
1. The first of which is the following line of code from the basic usage:
install(Resilience4jModule.class);
The error I get from that can be seen below:
2. Later in the docs, about adding configuration, it uses an instance instead of passing in the class, but in calling the configure
method, I am getting an exception:
java.lang.ClassNotFoundException: io.github.resilience4j.metrics.CircuitBreakerMetrics
I’m not even trying to use CircuitBreaker
. Below is my code:
Resilience4jModule resilience = new Resilience4jModule();
resilience.configure(config -> config
.retry("elastic", retry -> retry
.maxAttempts(3)
.waitDurationInMillis(100)
)
);
install(resilience);
No idea why I’d be getting an exception about circuit breaking. I included the curcuitbreaker package in my gradle, and still I get the exception.
3. Missing explanations/definitions. For example, in the docs for retry, it references a retry
variable without any context around what that is. It also is too simple of an example to be useful, resolving with a string.
What if my promise resolves with a ReceivedResponse
from an external service that I am attempting to retry on failures? I can’t just instantiate one. Maybe some clarification needs to exist on what you are allowed to resolve from your promises that you attempt to retry.
At this point, I am attempting to use the annotation approach, but cannot get past the exception being thrown in bullet point 2.
Issue Analytics
- State:
- Created 5 years ago
- Comments:10 (8 by maintainers)
Top GitHub Comments
https://github.com/resilience4j/resilience4j/issues/204
@drmaas Created a PR and fixed the issue. A new
0.13.0-SNAPSHOT
should be created soon by TravisCI.