Support for transport socket matching on locality metadata (#34598)
This patch adds a metadata field to the [LocalityLbEndpoints](https://www.envoyproxy.io/docs/envoy/latest/api-v3/config/endpoint/v3/endpoint_components.proto#config-endpoint-v3-localitylbendpoints) configuration. The new field can be used to perform transport socket matching for all endpoints in a locality: ``` load_assignment: cluster_name: example_cluster endpoints: - metadata: # <----- This is new. filter_metadata: envoy.transport_socket_match: network.id: vpc-1 lb_endpoints: - endpoint: address: socket_address: address: 10.1.1.1 port_value: 11337 - endpoint: address: socket_address: address: 10.1.1.2 port_value: 11337 ``` Notice the ability to add metadata alongside the collection of endpoints. The transport socket matcher will still check the `envoy.transport_socket_match` metadata for an endpoint, but now if there is no match it will look at that field in its locality's metadata. This essentially allows one to set a transport socket match for groups of endpoints with a single metadata field, which can significantly improve scalability for deployments with many endpoints as shown in https://github.com/envoyproxy/envoy/issues/34530. Signed-off-by: Tony Allen <txallen@google.com> Mirrored from https://github.com/envoyproxy/envoy @ f0201e54683875efeecf09df7328ad374be52d2cmain
parent
cbbec7dbab
commit
8e9ace8219
2 changed files with 16 additions and 10 deletions
Loading…
Reference in new issue