open-consul/agent/xds/testdata
Freddy eb2b40b22d
Update filter chain creation for sidecar/ingress listeners (#11245)
The duo of `makeUpstreamFilterChainForDiscoveryChain` and `makeListenerForDiscoveryChain` were really hard to reason about, and led to concealing a bug in their branching logic. There were several issues here:

- They tried to accomplish too much: determining filter name, cluster name, and whether RDS should be used. 
- They embedded logic to handle significantly different kinds of upstream listeners (passthrough, prepared query, typical services, and catch-all)
- They needed to coalesce different data sources (Upstream and CompiledDiscoveryChain)

Rather than handling all of those tasks inside of these functions, this PR pulls out the RDS/clusterName/filterName logic.

This refactor also fixed a bug with the handling of [UpstreamDefaults](https://www.consul.io/docs/connect/config-entries/service-defaults#defaults). These defaults get stored as UpstreamConfig in the proxy snapshot with a DestinationName of "*", since they apply to all upstreams. However, this wildcard destination name must not be used when creating the name of the associated upstream cluster. The coalescing logic in the original functions here was in some situations creating clusters with a `*.` prefix, which is not a valid destination.
2021-11-09 14:43:51 -07:00
..
clusters connect: Remove support for Envoy 1.16 (#11354) 2021-10-27 18:51:35 -07:00
endpoints xds: prefer fed state gateway definitions if they're fresher (#11522) 2021-11-09 16:45:36 +00:00
listeners Update filter chain creation for sidecar/ingress listeners (#11245) 2021-11-09 14:43:51 -07:00
rbac connect: Remove support for Envoy 1.16 (#11354) 2021-10-27 18:51:35 -07:00
routes connect: Remove support for Envoy 1.16 (#11354) 2021-10-27 18:51:35 -07:00
alt-test-leaf-cert.golden Use golden files for gateway certs and fix listener test flakiness 2020-04-27 11:08:41 -06:00
alt-test-leaf-key.golden Use golden files for gateway certs and fix listener test flakiness 2020-04-27 11:08:41 -06:00
alt-test-root-cert.golden Use golden files for gateway certs and fix listener test flakiness 2020-04-27 11:08:41 -06:00
cache-test-leaf-cert.golden Always return a gateway cluster (#8158) 2020-06-19 13:31:39 -06:00
cache-test-leaf-key.golden Always return a gateway cluster (#8158) 2020-06-19 13:31:39 -06:00
db-test-leaf-cert.golden Always return a gateway cluster (#8158) 2020-06-19 13:31:39 -06:00
db-test-leaf-key.golden Always return a gateway cluster (#8158) 2020-06-19 13:31:39 -06:00
test-leaf-cert.golden Connect: allow configuring Envoy for L7 Observability (#5558) 2019-04-29 17:27:57 +01:00
test-leaf-key.golden Connect: allow configuring Envoy for L7 Observability (#5558) 2019-04-29 17:27:57 +01:00
test-root-cert.golden Connect: allow configuring Envoy for L7 Observability (#5558) 2019-04-29 17:27:57 +01:00