attempt_wait_until: The time the next attempt will take place.
backoff_config: Arbitrary JSON data that configures the backoff algorithm.
This changes the job retry logic to not put the job in a QUEUED state if the backoff configuration exists, and instead, put it in a DELAYED_ATTEMPT state, which also sets the attempt_wait_until field. Sets the timer for the jobs to move them out of DELAYED_ATTEMPT, and into QUEUED.
On failure, server loads DELAYED_ATTEMPT jobs at startup, loading the timers that will move them out of DELAYED_ATTEMPT and into QUEUED.
If an error occurs at this detached state, then loudly log error, and try again after 1s.
semver-minor
Adds three fields to Job:
state: DELAYED_ATTEMPT
attempt_wait_until
: The time the next attempt will take place.backoff_config
: Arbitrary JSON data that configures the backoff algorithm.This changes the job retry logic to not put the job in a
QUEUED
state if the backoff configuration exists, and instead, put it in aDELAYED_ATTEMPT
state, which also sets theattempt_wait_until
field. Sets the timer for the jobs to move them out ofDELAYED_ATTEMPT
, and intoQUEUED
.On failure, server loads
DELAYED_ATTEMPT
jobs at startup, loading the timers that will move them out ofDELAYED_ATTEMPT
and intoQUEUED
.If an error occurs at this detached state, then loudly log error, and try again after 1s.