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

Backport supress stateless packet to 0.10.x #1598

Merged

Conversation

lijunwangs
Copy link
Contributor

@lijunwangs lijunwangs commented Jul 10, 2023

Backport e652b6d from main to 0.10.x branch.

The implementation is different from the main branch due to the refactoring happened to main branch.

  1. The enforcement of the limit is done at the quinn-proto layer as it is where the endpoint generated packets being queued.
  2. The transmit_queue_contents_len to track the buffer contents length at quinn-proto::Endpoint layer.
  3. The outgoing_queue_contents_len to track the buffer contents length at Quinn::Endpoint layer
  4. Quinn::Endpoint uses the new interface set_socket_buffer_fill exposed by proto::Endpoint to communicate the updated outgoing_queue_contents_len

@lijunwangs
Copy link
Contributor Author

Hi Ben/Dirkjan, can you please review the backport implementation of e652b6d to the 0.10.x release? @Ralith @djc

quinn-proto/src/endpoint.rs Outdated Show resolved Hide resolved
Copy link
Collaborator

@Ralith Ralith left a comment

Choose a reason for hiding this comment

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

Ah, I see why you were thinking about separate methods now. I'm happy either way.

quinn-proto/src/tests/mod.rs Outdated Show resolved Hide resolved
quinn-proto/src/endpoint.rs Outdated Show resolved Hide resolved
Copy link
Collaborator

@Ralith Ralith left a comment

Choose a reason for hiding this comment

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

This looks good so far, but did you also want to disable version negotiation and stateless reset packets under the heavily loaded condition?

@lijunwangs
Copy link
Contributor Author

This looks good so far, but did you also want to disable version negotiation and stateless reset packets under the heavily loaded condition?

Great point! I reviewed the implementation in main -- we were suppressing version negotiation and stateless reset packets as well. I will add these into the consideration as well to keep it consistent and more robust.

Copy link
Collaborator

@Ralith Ralith left a comment

Choose a reason for hiding this comment

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

LGTM, thanks!

@Ralith Ralith merged commit 53083f4 into quinn-rs:0.10.x Jul 13, 2023
8 checks passed
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.

None yet

2 participants