-
-
Notifications
You must be signed in to change notification settings - Fork 2.5k
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
udp: Add split/into_split for UdpSocket #3358
Conversation
This code currently fails on the visibility of |
They should be exported in a new module |
There appears to be a merge conflict. |
I gave it a rebase off the latest master, didn't see any conflicts but it should now have the latest changes. |
Split exists for |
It's not necessary, but |
|
My mistake, I should have double checked before commenting. |
Closing in favor of #3448. |
I dont know why this is closed. There is no way to split a udp socket so how one writes something using udp sockets? @carllerche what makes you think udp sockets must be unsplittable ? one very simple usage is to pass two ends to two different tasks so simultaneous read/writes are possible |
This was closed because you can already use an |
Motivation
With #2779 we don't need the split API anymore, however it still exists for
UnixStream
andTcpStream
. Why not also forUdpSocket
? It uses regular references or anArc
in the same way that the other types do.Solution
Write a simple wrapper over regular references for shared split or Arc for owned split. @Darksonn seemed to be on board for this, thoughts?