-
Notifications
You must be signed in to change notification settings - Fork 572
Added HTTP/2 support in conformance test roundtripper #1983
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
Conversation
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: ibilalkayy The full list of commands accepted by this bot can be found here.
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
Hi @ibilalkayy. Thanks for your PR. I'm waiting for a kubernetes-sigs member to verify that this patch is reasonable to test. If it is, they should reply with Once the patch is verified, the new status will be reflected by the I understand the commands that are listed here. Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
not really a comment on the exact content of the change, but should we err on the side of adding these sorts of changes along with the tests that need them? I don't think there are any such conformance tests that test HTTP/2 backend capabilities at the moment
Agree with @sunjayBhatia here, this would be best to save until we have test(s) that need this. @ibilalkayy was there a specific test you were hoping this would enable? |
PR needs rebase. Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
Unless, I'm missing something, I believe one can already achieve the requirements of the issue. Refer comment #1982 (comment) Please correct me if I misunderstood something. |
All the existing conformance tests use a known backend that is deployed as part of the tests (the ingress-conformance echo server) so there isn't anything in the tests I'm aware of that an HTTP/2 backend is relevant for yet (the still-draft conformance tests for gRPC route look like they will have their own gRPC echo server but will use a gRPC client) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. I was thinking of passing the client. But this seems like a better solution.
just important note for e2e tests and something that is a terrible headache is that grpc uses http2 under the hood https://github.com/grpc/grpc/blob/master/doc/PROTOCOL-HTTP2.md, so the only way to differentiate between http2 and grpc at the transport level is by checking the "content-type" header that should begin with "application/grpc" |
We are using conformance tests to test specific scenarios where we need http2 support. Currently we have a wrapper around the existing round tripper. But this native support will be much helpful going forward. @sunjayBhatia - Agree to your point on non-existence of any http2 related conformance test at the moment. Going forward do you see any support for http2 support in the near future? |
The outcome of this GEP should lead to some conformance tests being developed: #1979 |
As this PR hasn't received an update in some time, and needs some conflict resolution I'm going to mark this as "draft" for the time being as this helps us to better organize our reviews. Please let us know if you're blocked! |
What type of PR is this?
/kind feature
/area conformance
What this PR does / why we need it:
This PR adds support for HTTP/2 in the conformance test roundtripper package. The changes include updating the Request struct in roundtripper.go to include an HTTP2Transport field and modifying the defaultTransport function in roundtripper.go to create an HTTP/2 transport if required, using the http2.ConfigureTransport function from the golang.org/x/net/http2 package.
These changes will enable users to set the HTTP2Transport field when creating a Request in the conformance test, allowing for HTTP/2 support. This addition helps overcome the limitation of just using HTTP/1 in the conformance test, especially when the upstream backend host might only support HTTP/2.
Which issue(s) this PR fixes:
Fixes #1982
Does this PR introduce a user-facing change?:
Added support for HTTP/2 in the conformance test roundtripper package.