Problem migrate code from tokio 0.2 to 1.20 #4856
-
|
Beta Was this translation helpful? Give feedback.
Answered by
Noah-Kennedy
Jul 24, 2022
Replies: 2 comments
-
source code is here: |
Beta Was this translation helpful? Give feedback.
0 replies
-
The Tokio APIs changed significantly between The main issues I see here are that |
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
Noah-Kennedy
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The Tokio APIs changed significantly between
0.2
and1.0
, as1.0
was when the APIs were stabilized. Please read through the API docs.The main issues I see here are that
delay_for
has been replaced bysleep
and thatUdpSocket
no longer provides a splitting API (just put it in an Arc and clone it).