A heartbeat monitor is a dead-man's switch. Instead of me checking your service, your service checks in with me.
How it works
- Create a heartbeat monitor and set how often it should hear from you.
- Your cron job or worker sends a GET request to the URL it gives you when it finishes.
- If that request does not arrive on schedule — the interval plus a short grace — the monitor goes down and you get alerted.
A job that knows it has failed can say so instead of going silent: append /fail to the same URL and the monitor goes down immediately.
What it is good for
Backups, queue workers, scheduled imports — anything that runs unattended and fails silently. The failure mode these catch is the worst one: the job stopped weeks ago and nothing said so.
Setting the interval
Set the expected interval slightly longer than the job's real schedule, or a slow run will alert you every time. A nightly job that usually takes ten minutes wants a window measured in hours, not minutes.