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

h3: add support for additional HEADERS #1027

Merged
merged 2 commits into from
Sep 27, 2024

Conversation

LPardue
Copy link
Contributor

@LPardue LPardue commented Aug 24, 2021

HTTP/3 request and response message exchanges allow multiple HEADERS
frames to be sent, which allows for trailer sections or non-final
responses. Previously, quiche has only supported generating a single
HEADERS frame per request or response, and didn't support receiving
them.

This change adds support for sending and receiving multiple HEADERS
frames on a request stream. It enforces the sequencing rules defined in
https://datatracker.ietf.org/doc/html/draft-ietf-quic-http-34#section-4.1.
Sending additional HEADERS is done using the new
send_additional_headers() method. On the receive side, rather than add
a new Event enum variant for these additional uses of HEADERS, this
change reuses Event::Headers. Previosuly, this event included a
has_body boolean, which has been renamed to more_frames to better
align with how HTTP/3 streams work.

@LPardue LPardue requested a review from a team as a code owner August 24, 2021 01:37
@LPardue
Copy link
Contributor Author

LPardue commented Aug 24, 2021

Oh wow. The build failure is in data_event_rearm, there's a part of the test that says // Send more data, then HEADERS, then more data. - that isn't a valid sequence, so I guess this change has revealed a latent bug. Can we just remove that part of the test, or does it invalidate the rearm code/test?

src/h3/stream.rs Outdated Show resolved Hide resolved
@LPardue LPardue force-pushed the lucas/informational-and-trailing-headers branch from fca5a61 to 13401b4 Compare January 27, 2022 14:27
@LPardue
Copy link
Contributor Author

LPardue commented Jan 27, 2022

@ghedo since there is no way to send DATA frames after headers, I tried addressing the broken test by sending more data on a different stream and basically interleaving operations to see if the DATA event rearms properly.

A different approach might be, if we add an event for PRIORITY_UPDATE, to interleave that with DATA events. If we like the sound of that I can replace the fix data_event_rearm test commit with an alternative. Or we change it later, or whatever.

nginx/nginx-1.16.patch Outdated Show resolved Hide resolved
@LPardue LPardue force-pushed the lucas/informational-and-trailing-headers branch from 0305fcb to b4c4a98 Compare January 28, 2022 15:50
@LPardue LPardue force-pushed the lucas/informational-and-trailing-headers branch from b4c4a98 to 897e019 Compare September 6, 2022 22:14
@LPardue LPardue force-pushed the lucas/informational-and-trailing-headers branch 6 times, most recently from d29e589 to 1ab5eaa Compare November 29, 2022 16:15
HTTP/3 request and response message exchanges allow multiple HEADERS
frames to be sent, which allows for trailer sections or non-final
responses. Previously, quiche has only supported generating a single
HEADERS frame per request or response, and didn't support receiving
them.

This change adds support for sending and receiving multiple HEADERS
frames on a request stream. It enforces the sequencing rules defined in
https://www.rfc-editor.org/rfc/rfc9114.html#section-4.1.
Sending additional HEADERS is done using the new
`send_additional_headers()` method. On the receive side, rather than add
a new Event enum variant for these additional uses of HEADERS, this
change reuses Event::Headers. Previosuly, this event included a
`has_body` boolean, which has been renamed to `more_frames` to better
align with how HTTP/3 streams work.
@LPardue LPardue force-pushed the lucas/informational-and-trailing-headers branch from 1ab5eaa to 0e72799 Compare September 24, 2024 17:47
quiche/src/h3/mod.rs Outdated Show resolved Hide resolved
@ghedo ghedo merged commit 2514d58 into master Sep 27, 2024
39 checks passed
@ghedo ghedo deleted the lucas/informational-and-trailing-headers branch September 27, 2024 08:35
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.

3 participants