4 ms·
I think async exists and it works well. There were 2 equally popular runtimes earlier but now there's only 1 that everyone uses. I wouldn't characterise that as
by nindalf 4y ago
I think async exists and it works well. There were 2 equally popular runtimes earlier but now there's only 1 that everyone uses. I wouldn't characterise that as contention, just people trying different stuff out.
- galangalalgol 4y agoI still think async/await is a bit of a fad outside web services, and one I can't ignore if I want to use some popular crates.
- vlovich123 4y agoTokio is super popular but there are still better runtimes at the moment. The proper design you want is thread per core with some background pool of threads available for work stealing / batch jobs. The reason is that you can completely remove the need for any locking in your critical path. I think tokio is working on making that paradigm available but I don’t know how that’s progressing
- FridgeSeal 4y agoFor what it’s worth, Glommio is thread-per-core async executor library in Rust. Comes with io_uring support too. Not as widely supported as tokio is, obviously, but still viable enough, worth keeping an eye on IMO.
- vlovich123 4y agoYes that’s what I was referring to. I’m using that. ByteDance has a similar one although I haven’t tried it. The annoying thing is how deeply a specific async implementation “infects” all parts of the code. Would be nice for something more general so I could more easily test out individual implementations to compare performance vs having to rewrite a good chunk of the application.
- FridgeSeal 4y agoOh cool. Yeah I 100% agree, more executor-neutral API’s would be amazing. Especially for stuff like networking client libs, I wish hyper, Axum, tower, tonic, etc were all executor-neutral, or at least provided executor specialisations via features or something.