Function kitsune_p2p_types::metrics::metric_task
source · [−]pub fn metric_task<T, E, F>(f: F) -> JoinHandle<Result<T, E>>where
T: 'static + Send,
E: 'static + Send + Debug,
F: 'static + Send + Future<Output = Result<T, E>>,
Expand description
Spawns a tokio task with given future/async block. Captures a new TaskCounter instance to track task count.