background worker
A process that runs outside the request path and handles work such as publishing events or sending emails.
In more detail
The outbox relay is a background worker that polls for new outbox rows, publishes them and marks them sent. Running work in the background keeps user requests fast and lets failures be retried.
Related terms
- transactional outbox — Saving an event into an outbox table in the same database transaction as the business change, then having a separate worker publish it.
- message queue — A store that holds messages from producers until consumers are ready to process them, decoupling the rate of arrival from the rate of work.
- polling — Having the client ask repeatedly, on its own schedule, whether something has changed or finished.
Taught in
- Distributed Cache Invalidation: Redis & Tagged Purging — Production Full-Stack Engineering
- Asynchronous Event Processing: Outbox Pattern & Queues — Production Full-Stack Engineering