Reliable HTTP cron and delayed-job scheduling with automatic retries and full run logs — delay.run
"The workers are running" is not the same as "the work is on time". A queue can be accepting jobs, a process can be up, and the oldest unprocessed job can be 45 minutes past its run_at . If you only alert on process liveness or on a 5xx from the web app, you will learn about that 45 minutes from a customer.
Depth (how many jobs are waiting) and age (how late the oldest due job already is) are the two numbers that catch this. They are cheap to read if you measure them the same way the worker does, and expensive if you SELECT FOR UPDATE the live queue to do it.
What to measure
Two figures, per queue, on a short interval (30–60 seconds is plenty):
Depth: how many jobs are ready to run right now (due, not reserved, not done, not in a dead-letter).
Age: now minus the time the oldest of those jobs became runnable ( run_at or enqueued_at , depending on the system). Age of zero with depth of zero is healthy.…