-
Notifications
You must be signed in to change notification settings - Fork 110
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Annotation based Spring Cloud Circuit breaker #84
Comments
Could you not just use those annotations directly? |
If you would like us to look at this issue, please provide the requested information. If the information is not provided within the next 7 days this issue will be closed. |
Hello @ryanjbaxter, Just tried for the last couple of days. It seems the annotations @timed @count etc... are just from
The Spring Cloud Circuit breaker itself does not have the annotations (or am I using the wrong ones?) And if I combine the jars (have the resilience4j ones and spring cloud circuit breaker, the resilience4j ones works, but yield the same behavior as if only resilience4j jars, with no circuit breaker). |
If you are just going to use the Resilience4J annotations why would you include the spring cloud circuitbreaker jars? |
That's pretty much the purpose of this request for enhancement 😅 Is it possible to use spring cloud circuit breaker jar, without resilience4j, but still have the annotations? Currently, if I exclude resilience4j jars, just using spring cloud circuit breaker jars, there are no annotations at all (reason of this enhancement request) |
Yeah not currently we dont have annotations. The topic has come up before, I thought there was already an issue open for this but I can't seem to find it, so maybe it was just conversations we have had. Anyways we were waiting to see if there was enough demand from the community before actually adding any annotations. |
many thanks! Hope to see it one day |
I would also vote for annottations. Auto-Wiring the CircuitBreakerFactory and the replace the original method with factory.create().run() code is repeating over and over again, especiall when your are coming from @HystrixCommand. |
This would be definitively a great improvement. I think this would help a lot people who are migrating from hystrix-javanica. |
Is your feature request related to a problem? Please describe.
Problem: This project is amazing. However, currently, the application layer have to have code tied with the business logic to perform circuit breaker. The Spring Boot Starter Resilience4J project offers a very interesting set of annotations where methods can be annotated, and the decoration pattern will apply, making the code and understand of overall classes much clearer.
Describe the solution you'd like
A possibility to have annotations @CIRCUITBREAKER @Retry @timeout like Spring Boot Starter Resilience4J project, but for Spring-Cloud-CircuitBreaker. It is a very clean and nice feature
Describe alternatives you've considered
Well, right now, it is just a lot of code within the classes.
The text was updated successfully, but these errors were encountered: