Skip to content

test: cover built-in QUERY method parsing in HTTP/2 - #1781

Merged
He-Pin merged 1 commit into
apache:mainfrom
He-Pin:test/http2-built-in-query-method
Nov 28, 2026
Merged

He-Pin merged 1 commit into
apache:mainfrom
He-Pin:test/http2-built-in-query-method

Conversation

@He-Pin

@He-Pin He-Pin commented Nov 27, 2026

Copy link
Copy Markdown
Member

Motivation

HTTP/2 uses the built-in method registry for :method. Native QUERY parsing already has an HTTP/1.1 regression test, but the direct HTTP/2 method cases did not name QUERY.

Modification

Add one in-memory HTTP/2 request-model test using a normal QUERY request and assert that the built-in HttpMethods.QUERY is selected without custom registration. No production, routing, or network changes. The test does not assert entity delivery or application semantics.

Result

The focused test passed on JDK 17 with Scala 2.13.18 and Scala 3.3.9. Scoped formatting and whitespace checks passed. Full CI was not run locally.

References

Motivation:
The QUERY method is registered in the HTTP model and tested by the
HTTP/1 parser, but has no focused HTTP/2 request parser test.

Modification:
Parse one ordinary QUERY request through the existing in-memory
HTTP/2 fixture with default settings and assert the typed method.

Result:
The HTTP/2 request-parser test covers the built-in QUERY method
without changing production behavior.

References:
apache#1077
apache#1477
https://www.rfc-editor.org/rfc/rfc9113.html#section-8.3.1
https://www.rfc-editor.org/rfc/rfc10008.html#section-2
@He-Pin
He-Pin marked this pull request as ready for review November 27, 2026 20:31

@pjfanning pjfanning left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

lgtm

@He-Pin
He-Pin merged commit 771632d into apache:main Nov 28, 2026
6 checks passed
@He-Pin
He-Pin deleted the test/http2-built-in-query-method branch November 28, 2026 10:57
@pjfanning pjfanning added this to the 2.1.0 milestone Nov 29, 2026
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.

2 participants