refactor DAG and DAG consumers to support >2 Listeners#5128
refactor DAG and DAG consumers to support >2 Listeners#5128skriss merged 4 commits intoprojectcontour:mainfrom
Conversation
Codecov Report
Additional details and impacted files@@ Coverage Diff @@
## main #5128 +/- ##
==========================================
- Coverage 77.93% 77.86% -0.08%
==========================================
Files 138 138
Lines 17747 17757 +10
==========================================
- Hits 13831 13826 -5
- Misses 3650 3663 +13
- Partials 266 268 +2
|
2afed48 to
4cf3361
Compare
4cf3361 to
a17350f
Compare
|
Since there's no functional change here, not including a release note. I'll include a comprehensive one with the next PR to support >2 Listeners for Gateways. |
a17350f to
78a040d
Compare
78a040d to
07c03b8
Compare
Updates projectcontour#4960. Signed-off-by: Steve Kriss <krisss@vmware.com>
07c03b8 to
ccfd5c7
Compare
sunjayBhatia
left a comment
There was a problem hiding this comment.
this looks great! took a look at this and how its used in your other PR 👍🏽
| func (d *DAG) GetSecureVirtualHost(hostname string) *SecureVirtualHost { | ||
| return d.SecureVirtualHosts[hostname] | ||
| func (d *DAG) GetSecureVirtualHost(listener, hostname string) *SecureVirtualHost { | ||
| return d.Listeners[listener].svhostsByName[hostname] |
There was a problem hiding this comment.
in the future when we're doing some more dynamic listener additions/removals we may need to be more defensive here? (or make the invariant that the caller is in charge of knowing what valid listeners are so there aren't panics)
There was a problem hiding this comment.
Good call, yeah this is one of those things where logically the listener should always be there if we're asking to get/ensure a virtual host for it, but hard to guarantee that, so should probably be defensive.
There was a problem hiding this comment.
I'll plan to address this in the next PR when we add the dynamic listener handling
Signed-off-by: Steve Kriss <krisss@vmware.com>
…r#5128) Updates projectcontour#4960. Signed-off-by: Steve Kriss <krisss@vmware.com>
…r#5128) Updates projectcontour#4960. Signed-off-by: Steve Kriss <krisss@vmware.com> Signed-off-by: yy <yang.yang@daocloud.io>
Signed-off-by: yy <yang.yang@daocloud.io> add some unit test Signed-off-by: yy <yang.yang@daocloud.io> git rebase Signed-off-by: yy <yang.yang@daocloud.io> expose configuration for envoy's RateLimitedAsResourceExhausted (projectcontour#4971) The Rate Limit filter in Envoy translates a 429 HTTP response code to UNAVAILABLE as specified in the gRPC mapping document, but Google recommends translating it to RESOURCE_EXHAUSTED (see https://github.com/grpc/grpc/blob/master/doc/http-grpc-status-mapping.md) This commit introduces a new setting to allow contour to forward the same parameter introduced in envoyproxy/envoy#4879 The default value is disabled to retain the original behaviour of returning UNAVAILABLE, as changing it would be a breaking change. Closes projectcontour#4901. Signed-off-by: Víctor Roldán Betancort <vroldanbet@authzed.com> Signed-off-by: yy <yang.yang@daocloud.io> rebase Signed-off-by: yy <yang.yang@daocloud.io> update tracing config validate Signed-off-by: yy <yang.yang@daocloud.io> make generate Signed-off-by: yy <yang.yang@daocloud.io> add chengelog Signed-off-by: yy <yang.yang@daocloud.io> update make general Signed-off-by: yy <yang.yang@daocloud.io> goimport Signed-off-by: yy <yang.yang@daocloud.io> update tracing Signed-off-by: yy <yang.yang@daocloud.io> fix golint Signed-off-by: yy <yang.yang@daocloud.io> update test Signed-off-by: yy <yang.yang@daocloud.io> delete unused code Signed-off-by: yy <yang.yang@daocloud.io> delete error file Signed-off-by: yy <yang.yang@daocloud.io> update changelog Signed-off-by: yy <yang.yang@daocloud.io> fix some mistake Signed-off-by: yy <yang.yang@daocloud.io> feat: Add HTTP support for External Auth (projectcontour#4994) Support globally configuring an external auth server which is enabled by default for all vhosts, both HTTP and HTTPS. Closes projectcontour#4954. Signed-off-by: claytonig <claytonivorgonsalves@gmail.com> Signed-off-by: yy <yang.yang@daocloud.io> refactor DAG and DAG consumers to support >2 Listeners (projectcontour#5128) Updates projectcontour#4960. Signed-off-by: Steve Kriss <krisss@vmware.com> Signed-off-by: yy <yang.yang@daocloud.io> resolve conflict Signed-off-by: yy <yang.yang@daocloud.io> fix Signed-off-by: yy <yang.yang@daocloud.io>
Signed-off-by: yy <yang.yang@daocloud.io> add some unit test Signed-off-by: yy <yang.yang@daocloud.io> git rebase Signed-off-by: yy <yang.yang@daocloud.io> expose configuration for envoy's RateLimitedAsResourceExhausted (projectcontour#4971) The Rate Limit filter in Envoy translates a 429 HTTP response code to UNAVAILABLE as specified in the gRPC mapping document, but Google recommends translating it to RESOURCE_EXHAUSTED (see https://github.com/grpc/grpc/blob/master/doc/http-grpc-status-mapping.md) This commit introduces a new setting to allow contour to forward the same parameter introduced in envoyproxy/envoy#4879 The default value is disabled to retain the original behaviour of returning UNAVAILABLE, as changing it would be a breaking change. Closes projectcontour#4901. Signed-off-by: Víctor Roldán Betancort <vroldanbet@authzed.com> Signed-off-by: yy <yang.yang@daocloud.io> rebase Signed-off-by: yy <yang.yang@daocloud.io> update tracing config validate Signed-off-by: yy <yang.yang@daocloud.io> make generate Signed-off-by: yy <yang.yang@daocloud.io> add chengelog Signed-off-by: yy <yang.yang@daocloud.io> update make general Signed-off-by: yy <yang.yang@daocloud.io> goimport Signed-off-by: yy <yang.yang@daocloud.io> update tracing Signed-off-by: yy <yang.yang@daocloud.io> fix golint Signed-off-by: yy <yang.yang@daocloud.io> update test Signed-off-by: yy <yang.yang@daocloud.io> delete unused code Signed-off-by: yy <yang.yang@daocloud.io> delete error file Signed-off-by: yy <yang.yang@daocloud.io> update changelog Signed-off-by: yy <yang.yang@daocloud.io> fix some mistake Signed-off-by: yy <yang.yang@daocloud.io> feat: Add HTTP support for External Auth (projectcontour#4994) Support globally configuring an external auth server which is enabled by default for all vhosts, both HTTP and HTTPS. Closes projectcontour#4954. Signed-off-by: claytonig <claytonivorgonsalves@gmail.com> Signed-off-by: yy <yang.yang@daocloud.io> refactor DAG and DAG consumers to support >2 Listeners (projectcontour#5128) Updates projectcontour#4960. Signed-off-by: Steve Kriss <krisss@vmware.com> Signed-off-by: yy <yang.yang@daocloud.io> resolve conflict Signed-off-by: yy <yang.yang@daocloud.io> fix Signed-off-by: yy <yang.yang@daocloud.io>
Refactors DAG internals to support
any number of Listeners to prepare
for future changes to support many
Gateway Listeners.
Updates #4960.
I think this is in good shape, but as the design doc hasn't been merged yet leaving as draft for now.