Skip to content

WebTransport sendGroup support (and improve sendOrder)#3467

Open
jesup wants to merge 5 commits intousers/jesup/sub_protocolfrom
users/jesup/sendGroup
Open

WebTransport sendGroup support (and improve sendOrder)#3467
jesup wants to merge 5 commits intousers/jesup/sub_protocolfrom
users/jesup/sendGroup

Conversation

@jesup
Copy link
Copy Markdown
Member

@jesup jesup commented Mar 16, 2026

No description provided.

Copilot AI review requested due to automatic review settings March 16, 2026 04:43
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR adds WebTransport send group support to the QUIC transport and HTTP/3 layers, implementing the spec requirement that WebTransportSendGroups are treated as bandwidth-equals with per-group sendOrder namespacing. The changes introduce a SendGroupId type, per-group scheduling queues with round-robin fairness at the transport layer, and session-scoped send group registration/validation at the HTTP/3 layer.

Changes:

  • New SendGroupId and SendGroup types in neqo-http3, with a global atomic counter for unique IDs and a sentinel value (0) reserved for ungrouped streams.
  • Transport-layer scheduling refactored from flat sendordered/regular queues to per-group PerGroupQueues with round-robin between groups and sendOrder-based priority within each group.
  • HTTP/3 APIs for creating, registering, and validating send groups on WebTransport sessions, including stream creation with send group assignment.

Reviewed changes

Copilot reviewed 12 out of 12 changed files in this pull request and generated 10 comments.

Show a summary per file
File Description
neqo-http3/src/features/extended_connect/send_group.rs New file: SendGroupId newtype with atomic counter and SendGroup struct
neqo-http3/src/features/extended_connect/mod.rs Adds pub mod send_group
neqo-http3/src/features/extended_connect/webtransport_session.rs Session-level send group registration, validation, and storage
neqo-http3/src/features/extended_connect/webtransport_streams.rs WebTransportSendStream gains send_group field and trait impls
neqo-http3/src/features/extended_connect/session.rs Protocol trait extended with send group methods; forwarding impls
neqo-http3/src/lib.rs Re-exports SendGroupId; adds Stream/SendStream trait methods
neqo-http3/src/connection.rs Http3Connection gains send group set/clear, register/validate, and stream creation with send group
neqo-http3/src/connection_client.rs Public API: webtransport_set_sendgroup, webtransport_register_send_group, webtransport_create_stream_with_send_group
neqo-transport/src/send_stream.rs PerGroupQueues, refactored SendStreams with per_group IndexMap and round-robin scheduling
neqo-transport/src/streams.rs New SendGroupId type alias and set_sendgroup forwarding
neqo-transport/src/connection/mod.rs Public stream_sendgroup API on Connection
neqo-http3/src/features/extended_connect/tests/webtransport/sessions.rs Comprehensive tests for send group creation, validation, cross-session rejection, fair bandwidth allocation, and sendOrder within groups

Comment thread neqo-http3/src/lib.rs Outdated
Comment thread neqo-http3/src/features/extended_connect/webtransport_session.rs
Comment thread neqo-http3/src/features/extended_connect/send_group.rs
Comment thread neqo-http3/src/connection_client.rs
Comment thread neqo-http3/src/connection.rs
Comment thread neqo-http3/src/connection.rs Outdated
Comment thread neqo-http3/src/features/extended_connect/tests/webtransport/sessions.rs Outdated
Comment thread neqo-http3/src/features/extended_connect/send_group.rs Outdated
Comment thread neqo-http3/src/features/extended_connect/webtransport_session.rs Outdated
Comment thread neqo-transport/src/send_stream.rs Outdated
@jesup jesup changed the title Users/jesup/send group WebTransport sendGroup support (and improve sendOrder) Mar 16, 2026
@jesup jesup force-pushed the users/jesup/sub_protocol branch from c2bb439 to 58be5ff Compare March 17, 2026 18:43
@mxinden
Copy link
Copy Markdown
Member

mxinden commented Apr 1, 2026

Given the large merge conflicts, can you do another rebase before review? Can also review now, though I am afraid comments might get lost.

@larseggert
Copy link
Copy Markdown
Collaborator

It needs a rebase so CI runs

@larseggert larseggert added the needs-rebase PR needs rebasing before it can be merged. label Apr 8, 2026
@jesup jesup force-pushed the users/jesup/sub_protocol branch 2 times, most recently from c140eef to 723a367 Compare April 29, 2026 20:48
@jesup jesup force-pushed the users/jesup/sendGroup branch from 9c15fa5 to 9a89365 Compare April 29, 2026 20:48
@jesup
Copy link
Copy Markdown
Member Author

jesup commented Apr 29, 2026

jesup added 5 commits April 30, 2026 00:00
Fixes existing bug where low priority streams could be starved forever:
  After the highest-sendOrder stream within a group exhausted its queued data (but remained open),
  PerGroupQueues::next_stream_id() kept returning it, permanently starving lower-sendOrder streams
  in the same group.
@jesup jesup force-pushed the users/jesup/sendGroup branch from d564de8 to f5b9bdc Compare April 30, 2026 04:09
@github-actions
Copy link
Copy Markdown
Contributor

Failed Interop Tests

None ❓

All results

Succeeded Interop Tests

QUIC Interop Runner, client vs. server

neqo-pr as client

None ❓

neqo-pr as server

None ❓

Unsupported Interop Tests

QUIC Interop Runner, client vs. server

neqo-pr as client

None ❓

neqo-pr as server

None ❓

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

needs-rebase PR needs rebasing before it can be merged.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants