Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Generate inbound/outbound for HTTP/2 #998

Merged
merged 5 commits into from
Aug 31, 2020

Conversation

nickolaev
Copy link
Contributor

@nickolaev nickolaev commented Aug 28, 2020

Summary

As noted in #997, we have gaps in handling HTTP/2 and gRPC when generating the XDS configuration Snapshots. This PR proposes a fix for this on all the relevant places, plus adds/fixes the relevant tests.

Issues resolved

Fix #997 #991

Documentation

  • fixing internal issue

Nikolay Nikolaev added 3 commits August 28, 2020 16:46
Signed-off-by: Nikolay Nikolaev <nikolay.nikolaev@konghq.com>
Signed-off-by: Nikolay Nikolaev <nikolay.nikolaev@konghq.com>
Signed-off-by: Nikolay Nikolaev <nikolay.nikolaev@konghq.com>
@nickolaev nickolaev requested a review from a team as a code owner August 28, 2020 13:54
Copy link
Contributor

@lobkovilya lobkovilya left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I know this is a matter of taste, I've simply put here my suggestions

@@ -53,8 +53,10 @@ func (g InboundProxyGenerator) Generate(ctx xds_context.Context, proxy *model.Pr
filterChainBuilder := func() *envoy_listeners.FilterChainBuilder {
filterChainBuilder := envoy_listeners.NewFilterChainBuilder()
switch protocol {
// configuration for HTTP case
case mesh_core.ProtocolHTTP:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd still prefer :)

Suggested change
case mesh_core.ProtocolHTTP:
case mesh_core.ProtocolHTTP, mesh_core.ProtocolHTTP2:

fallthrough
case mesh_core.ProtocolHTTP2:
fallthrough
case mesh_core.ProtocolGRPC:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

and

Suggested change
case mesh_core.ProtocolGRPC:
case mesh_core.ProtocolHTTP, mesh_core.ProtocolHTTP2, mesh_core.ProtocolGRPC:

case mesh_core.ProtocolHTTP:
fallthrough
case mesh_core.ProtocolHTTP2:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
case mesh_core.ProtocolHTTP2:
case mesh_core.ProtocolHTTP, mesh_core.ProtocolHTTP2:

@tharun208
Copy link
Contributor

@nickolaev #991 is also fixed by this PR i think.

@jakubdyszkiewicz
Copy link
Contributor

Double tested with HTTP/2 and gRPC server client

Nikolay Nikolaev added 2 commits August 31, 2020 17:21
Signed-off-by: Nikolay Nikolaev <nikolay.nikolaev@konghq.com>
Signed-off-by: Nikolay Nikolaev <nikolay.nikolaev@konghq.com>
@nickolaev nickolaev merged commit ab791c8 into master Aug 31, 2020
@nickolaev nickolaev deleted the fix/generate_outbound_for_http2 branch September 17, 2020 05:45
nickolaev pushed a commit that referenced this pull request Oct 1, 2020
* fix(kuma-cp) generate RDS for HTTP, HTTP/2 and gRPC

* fix(kuma-cp) generate inbound also for HTTP/2

* test(kuma-cp) fix xds/generator test

Signed-off-by: Nikolay Nikolaev <nikolay.nikolaev@konghq.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Error when using HTTP/2 protocol on Inbound
4 participants