You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently a good portion of the lifetimes around types that take a reference to an executor type (like thread_pool or io_scheduler) do so by reference. Its generally assumed the executor will outlive all of its 'child' like task types that are driven by it, but this is not guaranteed. The general cost of moving to a shared ptr should be cheap enough to make sure the lifetime issues do not occur?
I think prototyping it out and the benchmarking would be an appropriate approach, short lived tcp_client's could possibly impose a penalty but its probably worth it safety wise.