Skip to main content

compensate_step

Function compensate_step 

Source
async fn compensate_step(
    state: &AppState,
    saga: &UnresolvedSaga,
    step: &UnresolvedStep,
    next_idx: &mut u32,
) -> Result<(), String>
Expand description

Undo one succeeded forward step. next_idx is the index for the recovery row this step writes; it moves on whenever a row was attempted, and stays put for a step whose command cannot be read.