make_worker

Function make_worker 

Source
pub fn make_worker<Fut1, Fut2>(
    token: CancellationToken,
    stop_check_duration: Duration,
    task_function: impl Fn(DateTime<Utc>) -> Fut1 + Send + Sync + 'static,
    stop_function: impl Fn() -> Fut2 + Send + Sync + 'static,
) -> JoinHandle<()>
where Fut1: Future<Output = LoopState> + Send, Fut2: Future<Output = ()> + Send,