3 ms·
You can use async network calls to handle multiple number of connections (in library code) yet use thread pool to write business logic (application code). I'm
by vbezhenar 7y ago
You can use async network calls to handle multiple number of connections (in library code) yet use thread pool to write business logic (application code).
I'm not suggesting to just use blocking I/O API. Non-blocking API like select/epoll/etc is very useful and should be utilized whenever possible. I'm about those language features.
- jchw 7y agoWhy is this approach nicer than event loops w/ async/await or goroutines? I think forcing humans to manually deal with continuations is not humane :)
- rowanG077 7y agoWhy do you want to make your code more complex by using select/epoll/etc and making continuation spaghetti instead of just embracing async?