When should an application use a background job?
Separate long-running or retryable application tasks with a predictable status and recovery model.
How to approach it
Move a task out of the request when it can take longer than a user or network should wait. Design how a user sees completion and what happens if the request is repeated. For a report export, track the source filters, progress and expiry of the resulting file.
Discuss this with DETAY TechWhat to prepare
- Define retries and when people can safely resubmit.
- Keep queued, completed and failed states distinct.
- Track how long jobs wait before processing starts.

