Function eventio::split

source ยท
pub fn split<D, A, I, O, F, S, R>(
    data_rx: Receiver<D>,
    ack_tx: Sender<A>,
    initialize: I,
    fold: O,
    finalize: F,
    nthreads: usize,
) -> Vec<JoinHandle<R>>
where D: 'static + Send + Event, <D as Event>::Ack: Into<A>, A: 'static + Send, I: 'static + Fn() -> S + Clone + Send, O: 'static + Fn(S, &D) -> S + Clone + Send, F: 'static + Fn(S) -> R + Clone + Send, R: 'static + Send,
Expand description

Spawns worker threads to process events in parallel.