API for LoadBalancing Strategy in EnvoyProxy API#1477
API for LoadBalancing Strategy in EnvoyProxy API#1477arkodg wants to merge 1 commit intoenvoyproxy:mainfrom
Conversation
* Allows the user to configure a global load balancing strategy
for the envoy proxy data plane
```
apiVersion: config.gateway.envoyproxy.io/v1alpha1
kind: EnvoyProxy
metadata:
name: set-lb-strategy
spec:
traffic:
loadBalancer:
strategy: LeastRequest
```
* Sets the default load balancing strategy to `LeastRequest` which
will internally set the `WeightedLeastReqquest` knob in Envoy
* Relates to envoyproxy#1256 allowing
the user to fall back to `ClusterIP` style loadbalancing
* Relates to envoyproxy#1105
Signed-off-by: Arko Dasgupta <[email protected]>
Codecov Report
@@ Coverage Diff @@
## main #1477 +/- ##
==========================================
- Coverage 61.77% 61.46% -0.32%
==========================================
Files 79 79
Lines 11490 11518 +28
==========================================
- Hits 7098 7079 -19
- Misses 3935 3979 +44
- Partials 457 460 +3
|
|
does gateway API support config this per route/backend? |
| // LoadBalancerStrategyClusterIP defines the "ClusterIP" load balancing strategy. | ||
| // In this mode, EnvoyProxy routes requests to the ClusterIP of the service and | ||
| // relies on another entity such as kube-proxy to perform load balancing to the upstream hosts. | ||
| LoadBalancerStrategyClusterIP LoadBalancerStrategy = "ClusterIP" |
There was a problem hiding this comment.
does this mean, eds will just send ClusterIP?
There was a problem hiding this comment.
yes, this is what is happening as of v0.4.0
There was a problem hiding this comment.
correct me if I'm wrong, only ClusterIP will change the result of EDS, other types only change LbPolicy on envoy cluster?
There was a problem hiding this comment.
this's a little odd to me, Is there any way to make them more consistent?
There was a problem hiding this comment.
can you share why its odd, this API is meant for end users (platform owners / app owners) to configure LB policy, so they can
- Use LB Policies provided at a L7 request level by Envoy (round-robin, least request, etc) or
- LB Policies provided at a L3/L4 flow level by another intermediate data plane entity such as kube-proxy
no, another way to expose this is to create a hierarchical policy called |
|
closing in favor of #1492 |
Sets the default load balancing strategy to
LeastRequestwhich will internally set theWeightedLeastRequestknob in EnvoyRelates to EndpointSlice Support #1256 allowing the user to fall back to
ClusterIPstyle loadbalancingRelates to proposal: LoadbalancingPolicy #1105