Function asyncify_run

Source
pub fn asyncify_run<F, T>(f: F) -> impl Future<Output = Result<T>>
where F: FnOnce() -> Result<T> + Send + 'static, T: Send + 'static,
Expand description

Spawns a blocking thread (using spawn_persistent_thread) that can be awaited on.

Dropping or cancelling the future is not a valid way to terminate the thread. Refer to spawn_persistent_thread for more information.