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

Support for QTIP and UDP on QUIC #3516

Open
srsubra opened this issue Mar 17, 2023 · 5 comments · May be fixed by #4803
Open

Support for QTIP and UDP on QUIC #3516

srsubra opened this issue Mar 17, 2023 · 5 comments · May be fixed by #4803
Assignees
Labels
Area: Lola Related to low latency work feature request A request for new functionality Partner: SQL By or For the SQL team
Milestone

Comments

@srsubra
Copy link

srsubra commented Mar 17, 2023

Describe the feature you'd like supported

QTIP feature allows QUIC to be sent over TCP/IP for the purposes of framing to leverage SLB fast path support in Azure. But this is a binary flag where the feature works either with UDP or with TCP. It would be better to have a listener support both endpoints to support clients connecting from op-prem and Azure simultaneously.

Proposed solution

Have an additional flag to support XDP with both QTIP and UDP in QUIC_EXECUTION_CONFIG_FLAGS like shown below
typedef enum QUIC_EXECUTION_CONFIG_FLAGS {
QUIC_EXECUTION_CONFIG_FLAG_NONE = 0x0000,
#ifdef QUIC_API_ENABLE_PREVIEW_FEATURES
QUIC_EXECUTION_CONFIG_FLAG_QTIP = 0x0001,
QUIC_EXECUTION_CONFIG_FLAG_ALL = 0x0002,
#endif
} QUIC_EXECUTION_CONFIG_FLAGS;

Additional context

No response

@srsubra srsubra added the feature request A request for new functionality label Mar 17, 2023
@nibanks nibanks added this to the Release 2.2 milestone Mar 20, 2023
@nibanks nibanks added the Area: Lola Related to low latency work label Mar 20, 2023
@nibanks nibanks modified the milestones: Release 2.2, Release 2.3 Mar 22, 2023
@nibanks nibanks moved this to Should be written in MsQuic Walkthroughs May 8, 2023
@nibanks nibanks modified the milestones: Release 2.3, Release 2.4 Oct 12, 2023
@nibanks nibanks added the Partner: SQL By or For the SQL team label Mar 14, 2024
@nibanks nibanks modified the milestones: Release 2.4, Release 2.5 Aug 29, 2024
@nibanks nibanks modified the milestones: Release 2.5, Future Jan 28, 2025
@ProjectsByJackHe ProjectsByJackHe moved this from Planned to In Progress in DPT Iteration Tracker Feb 5, 2025
@ProjectsByJackHe
Copy link
Contributor

UPDATE:

A couple of things:

  1. API update: we don't need to add a new EXECUTION_CONFIG_ALL flag, the current design should be interpreted as, if the QTIP flag is set, we ALLOW connections to send over QTIP and Listeners to accept QTIP connections. Bottom line, don't change anything with the global flags / state.

  2. In order to implement the behavior as specified in this issue, we ADD a new QUIC_SETTINGS parameter that specifies the option to use or don't use QTIP at the Connection/Listener layer. That means we need to update the Connection creation code and the Listener creation code to call into the Datapath layer to apply these state updates. If a Connection is created and we tell it to use QTIP, but the global EXECUTION_CONFIG_QTIP flag is set to OFF, then throw an error or something.

@anrossi
Copy link
Contributor

anrossi commented Feb 13, 2025

Regarding (2), I think it should be a separate SetParam parameter for listeners and connections, instead of in the QUIC_SETTINGS struct. Putting it in the QUIC_SETTINGS means that this niche feature is visible to many more users of MsQuic, and may encourage more to use it. My understanding is that it's a temporary solution to a specific Azure limitation. I'd rather not immortalize it in the QUIC_SETTINGS struct.

@nibanks
Copy link
Member

nibanks commented Feb 13, 2025

Regarding (2), I think it should be a separate SetParam parameter for listeners and connections, instead of in the QUIC_SETTINGS struct. Putting it in the QUIC_SETTINGS means that this niche feature is visible to many more users of MsQuic, and may encourage more to use it. My understanding is that it's a temporary solution to a specific Azure limitation. I'd rather not immortalize it in the QUIC_SETTINGS struct.

Great point! I agree.

@ProjectsByJackHe
Copy link
Contributor

ProjectsByJackHe commented Feb 14, 2025

Sounds good, so here's the new design:

Added 2 new Set/Get params. 1 for CONN, 1 for listener.

For now, we still keep the global EXECUTION_CONFIG_QTIP flag.
The idea here is that if the app did not explicitly set the CONN param for QTIP, then we will inherit what the global execution param is.

For the listener, the idea is that we will always support QTIP underneath the hood, but depending on the listener flag, we decide whether we care to bubble up any QTIP updates to the QUIC layer.

And again, if the app did not explicitly set the listener param, we will just inherit what the global execution config flag was.

@ProjectsByJackHe ProjectsByJackHe moved this from In Progress to Slipped in DPT Iteration Tracker Feb 25, 2025
@ProjectsByJackHe
Copy link
Contributor

UPDATE:

Here's the new design:
When an app configures MsQuic to use QUIC_EXECUTION_CONFIG_FLAG_QTIP ,
all listeners will be able to handle QUIC and QTIP traffic, and all client Connections created will be by default using QTIP.

However, you can use Connection setparams to control whether a client connection uses QTIP or QUIC. You can do this regardless of the state of QUIC_EXECUTION_CONFIG_FLAG_QTIP. You can not modify the Connection setparams for QTIP if the Connection is a part of a listener.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area: Lola Related to low latency work feature request A request for new functionality Partner: SQL By or For the SQL team
Projects
Status: Slipped
Development

Successfully merging a pull request may close this issue.

4 participants