This repository was archived by the owner on Apr 30, 2025. It is now read-only.
Generic Per-Route Options incl. Load Balancing Algorithm#428
Merged
maxmoehl merged 33 commits intocloudfoundry:mainfrom Jul 23, 2024
Merged
Generic Per-Route Options incl. Load Balancing Algorithm#428maxmoehl merged 33 commits intocloudfoundry:mainfrom
maxmoehl merged 33 commits intocloudfoundry:mainfrom
Conversation
|
|
f119e46 to
1025d7f
Compare
maxmoehl
reviewed
Jul 18, 2024
Member
maxmoehl
left a comment
There was a problem hiding this comment.
I've focused on the actual code, I'll review the tests once we have the first round of reviews in.
maxmoehl
reviewed
Jul 19, 2024
maxmoehl
reviewed
Jul 19, 2024
maxmoehl
reviewed
Jul 19, 2024
maxmoehl
reviewed
Jul 19, 2024
maxmoehl
reviewed
Jul 19, 2024
stefanlay
suggested changes
Jul 19, 2024
Contributor
Author
@stefanlay Thanks! |
stefanlay
approved these changes
Jul 20, 2024
a18e
added a commit
to sap-contributions/gorouter
that referenced
this pull request
Oct 22, 2024
Shows the lb algorithm of each endpoint in Gorouters /routes page. This simplifies debugging of related issues. The option to set route-specific load balancing algorithms was introduced in cloudfoundry#428.
1 task
MarcPaquette
pushed a commit
that referenced
this pull request
Oct 22, 2024
Shows the lb algorithm of each endpoint in Gorouters /routes page. This simplifies debugging of related issues. The option to set route-specific load balancing algorithms was introduced in #428.
This was referenced Dec 12, 2024
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Detailed specification including that of for all the involved components is provided in the RFC
Route definition is extended by generic options map with a load balancing algorithm. Options can be optionally specified in the following way with a json key lb_algo for the load balancing algorithm, e.g.
Supported load-balancing algorithms are specified in the Gorouter configuration in the LoadBalancingStrategies list. If a load balancing algorithm, provided for a route, is not in this configured list, the pool load balancing algorithm is kept and the error invalid-endpoint-load-balancing-algorithm-provided-keeping-pool-lb-algo is logged.
RegistryMessage structure is extended by an Options field of type RegistryMessageOpts structure, currently only containing the LoadBalancingAlgorithm field. Endpoint structure is extended by LoadBalancingAlgorithm field.
When initialising new endpoints, the load balancing algorithm is initialised to the value from the corresponding registry message option. When endpoints are registered and added to the pool, the load balancing algorithm of a pool is set to that one of a new endpoint.
RouteRegistry structure is extended by a new field DefaultLoadBalancingAlgorithm, which is initialised by the Gorouter default load balancing configuration property LoadBalance. This default value is a default load balancing algorithm for a new pool.
Since the route options are optional, not providing them has no effect on the existing default load balancing algorithm logic.
Backward Compatibility
Breaking Change? No
Check list
Resolves: cloudfoundry/routing-release#421