Skip to content

Add HTTP/2 CONTINUATION frame support#71

Merged
s-ludwig merged 8 commits intovibe-d:masterfrom
gedaiu:continuation-frames
Mar 11, 2026
Merged

Add HTTP/2 CONTINUATION frame support#71
s-ludwig merged 8 commits intovibe-d:masterfrom
gedaiu:continuation-frames

Conversation

@gedaiu
Copy link
Copy Markdown
Contributor

@gedaiu gedaiu commented Mar 5, 2026

Implements HEADERS frame splitting into CONTINUATION frames when the HPACK-encoded header block exceeds the peer's MAX_FRAME_SIZE, replacing the previous assert(false) stubs.

Introduces an HTTP2FrameFlag enum to replace magic flag constants, fixes the MAX_FRAME_SIZE settings validation error code from FLOW_CONTROL_ERROR to PROTOCOL_ERROR per RFC 7540 §6.5.2, and adds integration tests covering normal responses, edge cases like 204 No Content and empty bodies, and server resilience against malformed connections.

@gedaiu gedaiu force-pushed the continuation-frames branch from 60b22a8 to 883e844 Compare March 5, 2026 21:17
@gedaiu gedaiu force-pushed the continuation-frames branch from 883e844 to 273884c Compare March 5, 2026 21:23
@gedaiu gedaiu force-pushed the continuation-frames branch from 88d1227 to 5859d06 Compare March 5, 2026 22:07
@gedaiu
Copy link
Copy Markdown
Contributor Author

gedaiu commented Mar 5, 2026

Finally, I managed to make the http2 tests pass on Windows. Unfortunately, curl does not support HTTP/2 on Windows, so I had to disable those tests. Feel free to update the tests if you manage to install a proper curl on the Windows runners.

Copy link
Copy Markdown
Member

@s-ludwig s-ludwig left a comment

Choose a reason for hiding this comment

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

It's really nice to have this at a basic working and tested state now! I didn't have the time to dig into the issues I encountered after manually integrating the code from the HTTP/2 branch on master - so having CURL work like this is a big milestone.

Did you try whether typical GET requests from Chrome/Firefox are also working?

@s-ludwig s-ludwig merged commit 609e812 into vibe-d:master Mar 11, 2026
22 checks passed
@gedaiu
Copy link
Copy Markdown
Contributor Author

gedaiu commented Mar 11, 2026

I only tested it with curl. I will do more work on this, and when it is closer to the spec, I will switch my apps to use it and test it properly with browsers.

@s-ludwig
Copy link
Copy Markdown
Member

Sounds good. I've also been wondering whether it would make sense to integrate an external test suite, similar to what I've done for DMDScript. That might help to speed up the process of identifying problematic parts of the code.

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