New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Replacement for Ribbon LB #177
Comments
Hi @ArtyomGabeev This is a valid issue and a topic that has yet to be evaluated by the team, probably following a discussion and decisions on Ribbon replacement for the entire Spring Cloud stack (that's the issue to observe on this: spring-cloud/spring-cloud-commons#553 ). Once there's an alternative chosen/ created, we would have to provide it for our OpenFeign integration as well. If you're interested in working on this bit, we will be happy to get the contribution. Will get back to you after we've done some progress on the other issue. |
Hey, Is it something planned ? |
Hi @Glosur . yes, we've merged a PR providing our own non-reactive LB client: |
Thanks for the anwser @OlgaMaciaszek I'd like to give it a try ! Any advice for this ? |
Hi @Glosur - as Hoxton is not a major release for SC OpenFeign, it's important to take into account that at this point, we need to start by adding Spring Cloud LoadBalancer to it without removing Ribbon. We have created all the necessary setup to use Spring Cloud LoadBalancer with both non-reactive and reactive setups - I guess for OpenFeign, for now, that would be the non-reactive version. We have also created spring-cloud-starter-loadbalancer. After including it in your project, you will get a If you carry this out with a project that previously worked with Ribbon, it will start failing as at various points in Feign Ribbon Client and other Ribbon dependencies are used explicitly; now, an alternative will have to be provided - for example, by switching to using a I guess there would be more questions, so for further discussion, feel free to contact me at gitter. |
Hi @Glosur - please let me know if you are going to work on it. If not, I will get it done soon. |
Hello ! I started looking at the code a bit but my computer died yesterday. No problem if you get it done, I'll look at how you will do it |
Ok. Will work on it now. |
httpclient and okhttp setup. Add autoconfiguration. Init fix for gh-177.
* Add FeignBlockingLoadBalancerClient, configurations for default, apache httpclient and okhttp setup. Add autoconfiguration. Init fix for gh-177. * Fix SC loadbalancer dependencies. * Fix generating Feign response when instance not found. * Fix configuration. * Add tests for FeignBlockingLoadBalancerClient and FeignLoadBalancerAutoConfiguration. * Fix checkstyle and formatting. * Refactor, add docs and javadocs. * Fix author name. * Fix docs after code review.
Enhancement
As I understand, currently feign supports only Ribbon as client side loadbalancer, which is tight to Eureka.
Since we introduced DiscoveryClient interface, which may be k8s, predefined, etc and have clean interfaces like LoadBalancerClient/ServiceInstanceChooser and ReactiveLoadBalancer,
I think it will be nice to have at least Round Robin LB based on high level DiscoveryClient.
It will allows us to choose between different discovery mechanisms (I'm currently interested in k8s discovery) and provide a basic LB support for feign.
Questions:
Thanks
The text was updated successfully, but these errors were encountered: