Whats the difference between an asio::thread_pool
and an asio::io_context
whose run()
function is called from multiple threads? Can I replace my boost::thread_group
of threads that call io_context::run()
with an asio::thread_pool
? Or do I need somewhere an io_context
?
Update
When I use asio::thread_pool
, do I still need an io_context
to use sockets, timers, etc? Both thread_pool
and io_context
are an asio::execution_context
. However, the docs say on io_context
that it "Provides core I/O functionality". Do I lose these if I only use an asio::thread_pool
without an io_context
?