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

NetworkTarget - HttpNetworkSender no longer sends out-of-order #3546

Merged
merged 1 commit into from
Aug 22, 2019

Conversation

snakefoot
Copy link
Contributor

@snakefoot snakefoot commented Aug 13, 2019

And will flush correctly (delays flush completed until request completed). Resolves #3544 (See also #3542)

Will probably also improve the allocation pattern, as TCP-NetworkSender will delay allocation of SocketAsyncEventArgs-instances until ready to send. This will reduce the chance that they enter GC1.

Ofcourse the allocation pattern could become even better by reusing the SocketAsyncEventArgs-instance for the next TCP-NetworkSender-operation. And one could improve it even more by allocating byte-arrays in predefined sizes (512 bytes. 1024 bytes. 2048 bytes, etc.). And then check if room is available in the previous unsent allocated byte-array before creating new.

@snakefoot snakefoot force-pushed the NetWorkTargetHttpQueueSender branch 3 times, most recently from c8e50c0 to dff0b1f Compare August 14, 2019 20:27
@snakefoot
Copy link
Contributor Author

snakefoot commented Aug 14, 2019

Added unit test that shows that it will not discard pending http-requests because one http-request has failed (NetworkTarget still discards active HttpNetworkSender on error, and creates new)

@304NotModified
Copy link
Member

Cool!

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

Successfully merging this pull request may close these issues.

2 participants