Skip to content

feat: Enable fragmentation for unreliable delivery (UTP) #1512

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

Merged
merged 9 commits into from
Dec 9, 2021

Conversation

simon-lemay-unity
Copy link
Contributor

Modify the UTP adapter to send Unreliable and UnreliableSequenced traffic through fragmented pipelines. This makes it so that all delivery methods will support fragmentation in the adapter. This also means the 'Send Queue Batch Size' setting now controls the maximum payload size for all delivery methods, not just the reliable ones.

I'm debating backporting this change to 1.0.0, since this is mostly made in anticipation of the snapshot support. Thoughts?

Changelog

com.unity.netcode.adapter.utp

  • Changed: All delivery methods now support fragmentation, meaning the 'Send Queue Batch Size' setting (which controls the maximum payload size) now applies to all delivery methods, not just reliable ones.

Testing and Documentation

  • Includes unit/integration tests.
  • No documentation changes or additions were necessary.

@@ -54,7 +62,7 @@ public IEnumerator Cleanup()

// Check if can make a simple data exchange.
[UnityTest]
public IEnumerator PingPong()
public IEnumerator PingPong([ValueSource("k_DeliveryParameters")] NetworkDelivery delivery)
Copy link
Contributor

@0xFA11 0xFA11 Dec 8, 2021

Choose a reason for hiding this comment

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

I didn't know about [ValueSource("k_DeliveryParameters")] syntax, nice!

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.

5 participants