-
Notifications
You must be signed in to change notification settings - Fork 664
feat(loadbalancer): Add LoadBalancerType Client Side Weighted Round Robin #7407
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
base: main
Are you sure you want to change the base?
Conversation
9a814bd to
573a483
Compare
|
@jukie I have added the implementation and also tested it on my local setup PS: the repo is so easy to contribute everything just works with the docs given on the site :) |
|
Also I wanted to know should I include slow start in client wrr? So the thing is that I have submitted the proposal in grpc-xds grpc/proposal#498 and also in envoy I have got the proto updated. It is not implemented yet, but I am trying to pick it up this month if my time allows |
|
Also I am unsure of how to test this e2e, so I have just included an AI generated e2e test suite. The challenge here is that we need multiple replicas with each server respond with a specific header containing rps and cpu_utilisation and then the traffic is distributed by calculating the weight (rps / cpu) I don't know what the current e2e tests allow and if this type of test case is feasible to write |
5f3d64b to
ff2a353
Compare
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #7407 +/- ##
==========================================
+ Coverage 72.85% 72.89% +0.04%
==========================================
Files 237 237
Lines 35623 35690 +67
==========================================
+ Hits 25952 26017 +65
- Misses 7824 7827 +3
+ Partials 1847 1846 -1 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
I have started the implementation of slow_start_config and locality lb config with WRR as well, if possible I would also want to include them in the gatway implementation. |
|
We wait to add features here until they've made it into a full envoy release. The flow would be getting this lb support added for 1.7 and if your envoy changes get merged we can add that support to gateway in 1.8. Let's keep the scope of this PR to what's currently available and we can always include additional features in a follow-up. Are you able to make the suggested changes or can you join the contributors call next week to discuss? |
|
Sure, I just paused because the other changes were also approved, but I understand I will make the respective changes as suggested. Will try to complete them by today / tomorrow @jukie |
f926f90 to
c7ecca3
Compare
|
@jukie I have made the respective changes |
…Gateway CRDs, ensuring configurable parameters and validation rules are integrated. Includes e2e test for validation. Signed-off-by: anurag.ag <[email protected]>
Signed-off-by: anurag.ag <[email protected]>
Signed-off-by: anurag.ag <[email protected]>
…eway CRDs and related configurations. Update associated test data and documentation. Signed-off-by: anurag.ag <[email protected]>
…entSideWeightedRoundRobin configuration, update affected tests and CRDs. Signed-off-by: anurag.ag <[email protected]>
…cross Gateway CRDs, configuration files, and related tests. Adjust documentation to reflect percentage-based representation. Signed-off-by: anurag.ag <[email protected]>
a0471e0 to
dd5d285
Compare
|
Overall looks good, just a few more comments @anuragagarwal561994! Thanks for adding this and make sure to run Sorry for the delayed review on this. I'll prioritize helping you with this next week. |
|
This pull request has been automatically marked as stale because it has not had activity in the last 30 days. Please feel free to give a status update now, ping for review, when it's ready. Thank you for your contributions! |
|
@jukie can you help me resolve the changes I need to make with the above MR to make it releasable, I was on vacation for a while. I am back now and can work upon them |
…h `BackendUtilization` in Gateway CRDs, configurations, and tests. Revise validation rules, documentation, and enums accordingly. Signed-off-by: anurag.ag <[email protected]>
✅ Deploy Preview for cerulean-figolla-1f9435 ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
…ndUtilization` in load balancing tests and documentation. Signed-off-by: anurag.ag <[email protected]>
…on` across tests, configurations, and load balancing policies for consistency. Signed-off-by: anurag.ag <[email protected]>
…cing tests. Signed-off-by: anurag.ag <[email protected]>
|
This is in a pretty good state, thanks @anuragagarwal561994! If you'd like some help building the e2e or want to brainstorm feel free to DM in the envoy slack. |
I already have a e2e setup on my local that I had built with earlier changes using AI, I would need to do some modifications in it after the new changes and make it ready to be published in my repo, because I am currently using an internal library we built to consistently publish the server metrics across applications. |
…kend Utilization (ORCA) load balancing in Gateway CRDs and related docs. Refine header handling and metric formats. Signed-off-by: anurag.ag <[email protected]>
848b92f to
9a8f647
Compare
…ercent` across API, tests, and internal logic for clarity and precision. Adjust related documentation and validations. Signed-off-by: anurag.ag <[email protected]>
…n`. Adjust logic, tests, and documentation to highlight default value and ORCA header removal. Signed-off-by: anurag.ag <[email protected]>
621d26d to
9c9dc20
Compare
|
|
||
| gwAddr := kubernetes.GatewayAndRoutesMustBeAccepted(t, suite.Client, suite.TimeoutConfig, suite.ControllerName, kubernetes.NewGatewayRef(gwNN), &gwapiv1.HTTPRoute{}, false, routeNN) | ||
|
|
||
| t.Run("traffic should be split roughly evenly (defaults to equal weights without ORCA)", func(t *testing.T) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can we test the feature in the e2e ? i.e. have the backend craft a endpoint-load-metrics response header and use that in LB decision making
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@arkodg this we have discussed in earlier comment that it will take some time to build and can be done seaprately because this requires changes with the current echo application too.
What type of PR is this?
What this PR does / why we need it:
This PR provides addition of new load balancer type client side weighted round robin. This is a new load balancing extension introduced since envoy 1.32
https://www.envoyproxy.io/docs/envoy/latest/api-v3/extensions/load_balancing_policies/client_side_weighted_round_robin/v3/client_side_weighted_round_robin.proto
Which issue(s) this PR fixes:
Fixes #7305
Release Notes: Yes/No