Backend for AIintermediate11 min · 10 steps
Background Jobs
Run scheduled, triggered and handed-off work outside the request–response cycle, with explicit states, retries, timeouts and enough visibility that failures never go silent.
errordatarequestheavy worksignalresponse
ProblemStep 1 of 10
The nightly script nobody is watching
The knowledge base is re-indexed by a cron script on one VM. One night it runs long and the next run overlaps it. Another week the source credentials expire and it fails silently: the assistant quietly answers from stale articles for weeks.
Background work needs what request handlers get for free: someone notices when it fails.
Lesson 13 of 20 in Backend for AI