With coroutines multithreading is "cooperative". It's your job to release control to the run-loop.
Doing it efficiently is an art and the OS is a lot more efficient than you, even with all the context switching. Going async is premature-optimization in my opinion, especially since with a Java server you can get to a couple thousands of synchronous requests/second easily.
Hmm, obviously you haven't written any serious http proxy/server that required to handle 10k+ of concurrent connections. Couple of thousands of sync connections is nothing in high performance servers.
There isn't much scheduling about coroutines, you wake up the coroutine on the event that it slept on (read/write/sleep), that's it. If you want to prioritize, you can do so, but with minimal advantage.
>Doing it efficiently is an art and the OS is a lot more efficient than you, even with all the context switching
At this point, I am pretty sure you don't understand context-switching and its implications, and you don't know how coroutines work.
Doing it efficiently is an art and the OS is a lot more efficient than you, even with all the context switching. Going async is premature-optimization in my opinion, especially since with a Java server you can get to a couple thousands of synchronous requests/second easily.
You also missed the point of the fucking article.