Skip to main content

run_transactional

Function run_transactional 

Source
pub async fn run_transactional(
    ctx: Arc<LoadContext>,
    path: LoadPath,
    latencies: Latencies,
) -> ProducerOutput
Expand description

The transactional producer of path, until the load stops.

Each transaction carries records_per_transaction paced sends, and every abort_every-th one is aborted on purpose. A transaction with a failed send is aborted. A commit or abort that returns an error leaves the producer in an unknown state, so it is closed and rebuilt under the same transactional id, whose InitProducerId settles what it left open. A commit that returned an error is recorded as TxnOutcome::Unknown; a transaction whose commit was never sent is aborted, whatever ended it.

latencies is where its send latencies go.