pub fn run<F, E>(fut: F) -> ManagedFutureExpand description
Boxes a future without spawning a separate managed task
Use this in [ManagedProc::start_task] impls when you want to run the future
directly rather than spawning it. Prefer spawn when possible, as spawned
tasks can run more efficiently on the Tokio runtime
§Example
ⓘ
impl ManagedProc for MyLocalDaemon {
fn start_task(self: Box<Self>, shutdown: ShutdownSignal) -> ManagedFuture {
super_visor::run(self.run(shutdown))
}
}