I want to write a distributed systems communication middleware using Rust similar to gigamsg but different behavior. I want to distribute a library which can be linked from C/C++/Java/whatever. I think Rust will be a good fit but now I am considering how to manage IO operations.
Does it make sense to start with a library like MIO, https://github.com/carllerche/mio/tree/master/src, with a event loop or should I just start spawning threads and using locking primitives? Seems like locking primitives is more idiomatic but maybe there's a big reason to jump straight in to something like MIO?
One thing to keep in mind is that mio has no windows support. If you're building a library which will be used by people who are used to cross-platform content (Java, python developers), that is a major disadvantage.
I read a little further and I see that Windows support is not intended for MIO. So that rules out the library for now. But that still leaves me with the question of whether the event loop/reactor/async IO pattern is the right one. I have glanced across some arguments from Rust people that async/coroutine style code is not as efficient as threaded code (I'm positive I'm getting that argument wrong).
@xrl Just Found your post from Google search.
I'm also thinking about developing network IO based application with MIO ... Are you decided to use MIO about a year ago ?