When you build a web application, not every task should happen inside the user's request.
Some work is slow. Some work can fail. Some work should happen later. Sending emails, resizing images, processing webhooks, generating reports, and retrying third party APIs are all good examples.
These tasks are usually handled by a background job system.
In this article, we will use a Go project I built called Swig as a practical example of how a PostgreSQL backed job queue can work.
The goal is not only to understand Swig. The goal is also to learn Go concepts that show up in real backend systems:






