Module driver

Module driver 

Source
Expand description

Shared DogStatsD load-driver engine.

The engine fetches a working set of contexts from the shared intake pool, then a producer thread renders per-occurrence values against them into a bounded channel while a consumer thread fans each datagram out to every socket and tallies per-socket sends. Drivers differ only in how many sockets they target and which anchors they fire, so both the single-socket and differential drivers run on this one engine.

NOTE: this driver intentionally blocks on backpressure from the SUT. Retry and backoff timers are meant to endure transient errors.

Structs§

Stats
What a driver run shipped, for anchoring assertions.

Functions§

connect_with_retry
Wait for the remote process to bind path, intentionally naive. Returns None if the socket is still unavailable after 30 seconds.
run
Pull context_count contexts from the intake pool at intake_addr once, then drive count datagrams to every socket from that one pull, each datagram a fresh per-occurrence render of every context that fits under limit_bytes, blocking through transient backpressure so every datagram reaches every socket. context_count, count, and limit_bytes come from a load generator’s crate::config::DriverConfig, so a datagram never truncates on receive.