-
Notifications
You must be signed in to change notification settings - Fork 124
QUIC multi-stream #1533
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
base: master
Are you sure you want to change the base?
QUIC multi-stream #1533
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||||||
|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -49,12 +49,28 @@ | |||||||||
| <li>Client or server MUST set the ALPN (&rfc7301;) TLS extension, and MUST use &tls-ech; if available.</li> | ||||||||||
| <li>The ALPN protocol MUST be '<strong>xmpp-client</strong>' when negotiating an c2s connection.</li> | ||||||||||
| <li>The ALPN protocol MUST be '<strong>xmpp-server</strong>' when negotiating an s2s connection.</li> | ||||||||||
| <li>The client or server MUST use <link url='https://datatracker.ietf.org/doc/html/rfc9000#section-9'>QUIC Connection Migration</link> which allows for a single QUIC session and therefore multiple XMPP connections to migrate between IPs without reconnecting. Use of &xep0198; is therefore optional but encouraged if reconnection might occur over another transport like TLS or WebSocket.</li> | ||||||||||
| <li>QUIC supports uni-directional and bi-directional streams, but XMPP MUST only use bi-directional streams. Multiple bi-directional MAY be opened in one session and MUST be treated as a seperate connections with the same security and authentication as negotiated in the initial TLS handshake. This means clients can log into multiple accounts, or the same account multiple times over one QUIC session, or servers can open multiple s2s connections over one QUIC session where one of the servers can prove control over multiple domains, for example if the certificate covered multiple domain names.</li> | ||||||||||
| <li>The client or server MUST use <link url='https://datatracker.ietf.org/doc/html/rfc9000#section-9'>QUIC Connection Migration</link> which allows for a single QUIC session and therefore multiple XMPP connections to migrate between IPs without reconnecting. The timeout SHOULD be set to the maximum 600 seconds.</li> | ||||||||||
|
||||||||||
| <li>The client or server MUST use <link url='https://datatracker.ietf.org/doc/html/rfc9000#section-9'>QUIC Connection Migration</link> which allows for a single QUIC session and therefore multiple XMPP connections to migrate between IPs without reconnecting. The timeout SHOULD be set to the maximum 600 seconds.</li> | |
| <li>The client or server MUST use <link url='https://datatracker.ietf.org/doc/html/rfc9000#section-9'>QUIC Connection Migration</link>, which allows a single QUIC session, and therefore the XMPP connection/XMLStream established over it, to migrate between IPs without reconnecting. The timeout SHOULD be set to the maximum 600 seconds.</li> |
Copilot
AI
Apr 30, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Connection migration keeps the same QUIC connection alive across address changes; it does not provide XEP-0198-style stream resumption after a disconnect/reconnect. Consider rephrasing to avoid implying that connection migration is a form of (or complete replacement for) session resumption.
Copilot
AI
Apr 30, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Typo: "bidirection" should be "bidirectional".
| <p>QUIC allows the use of multiple streams. A QUIC connection still maps to a single XMLStream, and the initial bidirection stream (id=0) SHALL be used to setup and make ready this XMLStream. Until the XMLStream is ready for general stanza exchange, further bidirectional QUIC streams MUST NOT be opened. For S2S XMLStreams, this will be after SASL authentication, whereas for C2S XMLStreams this will be after resource binding. It is advised to support &xep0388; and &xep0387; to streamline these, though there is no interoperability issue if the older forms are used.</p> | |
| <p>QUIC allows the use of multiple streams. A QUIC connection still maps to a single XMLStream, and the initial bidirectional stream (id=0) SHALL be used to setup and make ready this XMLStream. Until the XMLStream is ready for general stanza exchange, further bidirectional QUIC streams MUST NOT be opened. For S2S XMLStreams, this will be after SASL authentication, whereas for C2S XMLStreams this will be after resource binding. It is advised to support &xep0388; and &xep0387; to streamline these, though there is no interoperability issue if the older forms are used.</p> |
Copilot
AI
Apr 30, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Grammar: "to setup" should be "to set up" when used as a verb phrase.
| <p>QUIC allows the use of multiple streams. A QUIC connection still maps to a single XMLStream, and the initial bidirection stream (id=0) SHALL be used to setup and make ready this XMLStream. Until the XMLStream is ready for general stanza exchange, further bidirectional QUIC streams MUST NOT be opened. For S2S XMLStreams, this will be after SASL authentication, whereas for C2S XMLStreams this will be after resource binding. It is advised to support &xep0388; and &xep0387; to streamline these, though there is no interoperability issue if the older forms are used.</p> | |
| <p>QUIC allows the use of multiple streams. A QUIC connection still maps to a single XMLStream, and the initial bidirection stream (id=0) SHALL be used to set up and make ready this XMLStream. Until the XMLStream is ready for general stanza exchange, further bidirectional QUIC streams MUST NOT be opened. For S2S XMLStreams, this will be after SASL authentication, whereas for C2S XMLStreams this will be after resource binding. It is advised to support &xep0388; and &xep0387; to streamline these, though there is no interoperability issue if the older forms are used.</p> |
Copilot
AI
Apr 30, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The example JIDs appear to contradict the stated rule. It says both stanzas MUST use the same QUIC stream because they are between the same bare JID pair, but the second stanza is addressed to "receiver@sender.com/xyzzy" (a different bare JID/domain than "receiver@example.com"). Please correct the example addresses so they demonstrate the intended same bare-JID-pair case.
| <p>Once multiple streams are opened, it is MANDATORY that both peers continue to follow the ordering rules defined in Section 10.1 of &rfc6120;, however stanzas sent in different QUIC streams have no fixed order relative to those sent in other QUIC streams. The sending peer MUST therefore use a single QUIC stream for all stanzas sent between a pair of two bare jids. For example, when sending a stanza from sender@example.net/resource to receiver@example.com, and another from sender@example.net/other to receiver@sender.com/xyzzy, both stanzas MUST be sent within the same QUIC stream. Multiple "pairs" of Jids MAY share the same QUIC stream, with the degenerate case - all pairs sharing the same QUIC stream - being the case where no additional QUIC streams are opened. This mapping of bare jid pairs to QUIC streams MUST NOT be enforced by the receiver; the receiver MUST simply process all stanzas received over a QUIC stream in the order they were sent in the same way they would if a single QUIC stream (or TCP) were used.</p> | |
| <p>Once multiple streams are opened, it is MANDATORY that both peers continue to follow the ordering rules defined in Section 10.1 of &rfc6120;, however stanzas sent in different QUIC streams have no fixed order relative to those sent in other QUIC streams. The sending peer MUST therefore use a single QUIC stream for all stanzas sent between a pair of two bare jids. For example, when sending a stanza from sender@example.net/resource to receiver@example.com, and another from sender@example.net/other to receiver@example.com/xyzzy, both stanzas MUST be sent within the same QUIC stream. Multiple "pairs" of Jids MAY share the same QUIC stream, with the degenerate case - all pairs sharing the same QUIC stream - being the case where no additional QUIC streams are opened. This mapping of bare jid pairs to QUIC streams MUST NOT be enforced by the receiver; the receiver MUST simply process all stanzas received over a QUIC stream in the order they were sent in the same way they would if a single QUIC stream (or TCP) were used.</p> |
Copilot
AI
Apr 30, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Typo: "proritise" should be "prioritize" (or "prioritise", but currently it's misspelled).
| <p>The benefits of doing this are that individual streams do not block each other on low bandwidth or packet loss. Eliminating this blocking effect, called Head Of Line Blocking, means that higher-volume chatrooms (for example) do not slow down the transmission of perhaps more urgent low volume messages. Because of this effect, peers MAY use QUIC's ability to proritise specific QUIC streams for finer control, though this is out of scope for this document.</p> | |
| <p>The benefits of doing this are that individual streams do not block each other on low bandwidth or packet loss. Eliminating this blocking effect, called Head Of Line Blocking, means that higher-volume chatrooms (for example) do not slow down the transmission of perhaps more urgent low volume messages. Because of this effect, peers MAY use QUIC's ability to prioritise specific QUIC streams for finer control, though this is out of scope for this document.</p> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"The timeout SHOULD be set to the maximum 600 seconds" is ambiguous (which QUIC timeout/transport parameter?) and appears to state a universal maximum that QUIC does not define. Please specify the exact QUIC mechanism/parameter (and units) and avoid asserting a fixed protocol maximum unless it is referenced/normatively defined.