Skip to main content

after_attempt

Function after_attempt 

Source
pub fn after_attempt(
    status: AttemptStatus,
    error_kind: Option<&str>,
    retries_used: u32,
    settings: &TaskSettings,
    cancelling: bool,
    now: Timestamp,
) -> AfterAttempt
Expand description

Decides what follows an attempt with status (and the error kind schedr recognised, if any), given how many retries the task used before it and whether the task or its run is being cancelled (then nothing runs again, a failure stays a failure, and an attempt lost with its worker is cancelled).