run

Function run 

Source
pub fn run<R: Rng + Send + 'static>(
    rng: R,
    batch: Batch,
    limit_bytes: usize,
    count: usize,
    sockets: Vec<UnixDatagram>,
) -> Result<Stats>
Expand description

Drive count sampled DogStatsD datagrams to every socket, packing each to at most limit_bytes and blocking through transient backpressure so every datagram reaches every socket. Both count and limit_bytes come from a load generator’s crate::config::DriverConfig, so a datagram never truncates on receive.

A peer that leaves mid-batch, or backpressure that outlasts the retry budget, ends the run early with a partial Stats rather than an error.

§Errors

Errors if a worker thread panics. Sustained backpressure is reported via Stats::timed_out, not as an error.