Repository navigation
feat: support opt-in HTTP/2 for HTTPS upstreams - #14284
Open
Zi-Yi-Ming wants to merge 1 commit into
Open
Zi-Yi-Ming wants to merge 1 commit into
Zi-Yi-Ming wants to merge 1 commit into
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Add
http_version: "2"for upstreams configured withscheme: https. This lets APISIX send ordinary HTTPS requests to a backend over HTTP/2. Omitting the field keeps the existing HTTP/1.1 behavior. The opt-in requires an NGINX core of 1.29.4 or later built withngx_http_v2_module.Related issue
Refs #13002. This covers the APISIX data plane portion of the feature request.
Validation
Ran
bash t/cli/test_https_upstream_http2.shon APISIX Runtime 1.4.3 with OpenResty 1.31.9.1. The test alternates requests to two routes that share the same TLS backend and checks the protocol reported by that backend.scheme: httpsandhttp_version: "2", the backend received HTTP/2 on both requests.scheme: httpsand nohttp_version, the backend received HTTP/1.1 on both requests.The existing HTTPS/gRPC TLS suite passed 88 assertions. The Admin and Control API validators, all 20 OpenAPI contract tests,
make lint, ShellCheck, andgit diff --checkpassed.Checklist