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

Align Slic connection dispose behavior with Quic #2225

Open
bernardnormier opened this issue Dec 7, 2022 · 4 comments
Open

Align Slic connection dispose behavior with Quic #2225

bernardnormier opened this issue Dec 7, 2022 · 4 comments
Labels
enhancement slic Slic Transport
Milestone

Comments

@bernardnormier
Copy link
Member

See #2183.

In general, I think Slic should behave like Quic whenever doable even if we think the Quic behavior is not the best. We can change Slic and keep in in sync with Quic over time; we have little control over .NET's Quic implementation.

In this particular case, SlicConnection.DisposeAsync should send a Close frame like Quic (or Quic will soon). The application error code would be a "default error code" set in the Slic options.

@pepone pepone added this to the 0.1 milestone Dec 12, 2022
@bentoi
Copy link
Contributor

bentoi commented Dec 14, 2022

    Really: the "accept requests loop" (or accept requests task) disposed the transport connection while this CloseAsync was in progress.

And presumably, transportConnection.DisposeAsync does not wait for an outstanding CloseAsync to complete: it aborts it. Is this the correct semantics for multiplexed connection?

See also dotnet/runtime#78641 (comment)

Originally posted by @bernardnormier in #2289 (comment)

@bernardnormier
Copy link
Member Author

Microsoft does not describe what they want to do when DisposeAsync is called while CloseAsync is in progress. Presumably it could be:
a) wait for the CloseAsync to complete
b) somehow abort the CloseAsync and wait for this aborted CloseAsync to complete

We should ask Manicka on this issue 78641.

And once we know, we do the same in Slic.

@bentoi
Copy link
Contributor

bentoi commented Mar 1, 2023

The protocol connection disposal is now abortive like Slic. If we allow the transport DisposeAsync to be graceful, would there still be a good reason for IProtocolConnection.DisposeAsync to not be graceful like Quic (graceful if ShutdownAsync didn't previous fail or was not called)?

Or should we push for a silent close implementation of QuicConnetion.DisposeAsync?

I'm moving to 0.2 for now.

@bentoi
Copy link
Contributor

bentoi commented Jan 30, 2024

See dotnet/runtime#96807 that fixes the issue I reported. We need to review how these changes are relevant with this issue.

For instance, SlicConnection.DisposeAsync is already abortive so Quic is now aligned with Slic. It's not clear however, if Quic and Slic behave the same when DisposeAsync is called while a CloseAsync call is in progress, it's likely.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement slic Slic Transport
Projects
None yet
Development

No branches or pull requests

3 participants