devlogquedulascheduling
Devlog #5: Publish queue and retries
Publishing in Quedula works through a queue: when the scheduled time arrives, the task enters a queue for a worker to execute.
This separates "when it needs to be published" from "when it actually got published." The worker might be busy with another task — no problem, the task waits.
For retries we store the attempt count and the next attempt time directly in the task record. On a transient failure, the task goes back to the queue with an incremented counter and a delay. After the maximum number of attempts, the task is marked as failed and the user receives a notification.
A simple model that works well in practice.