Heartbeat monitors
Check that a cron job or background task calls Greenbar on time.
What it checks
A heartbeat monitor doesn't call your job. Your job calls Greenbar when it finishes. The monitor is up when a ping arrives within the interval plus the grace period, and down when that window passes with no ping.
Before the first ping, and still inside the first window, the check records nothing and says it is waiting. After that window with no ping, it is down. A ping from before a pause doesn't count after you resume: the window starts again.
Add a monitor
- Choose Add monitor, and choose Cron job / scheduled task.
- Name the job, set how often it should run, and set Grace period (seconds).
- Choose Create monitor. Copy the ping URL from the next screen. It is shown only once.
- Call that URL with POST at the end of each successful run.
Name
What it does: How the monitor is listed.
Interval
What it does: How often the job should ping: 30 seconds, 1 minute, 5 minutes, 10 minutes, 30 minutes and 1 hour, no faster than your plan allows.
Grace period (seconds)
What it does: Extra time after the interval before a missed ping is down. It starts at 5 minutes. Anything else is refused:
Grace period must be 0 to 86400 seconds.
- There is no Timeout (ms). Grace period (seconds) replaces it.
- A missed window opens an incident, and the next ping closes it.
- A new heartbeat starts hidden on the public status page. Under Monitors on status page, tick Visible to show it.
- On the monitor, Rotate ping URL stops the current URL at once and shows a new one once.
Related page: Status page settings and notices, where Visible is.
The ping
The URL accepts POST only. A GET is refused with use POST, so a link preview can't count as a run. A successful ping answers ok.
- More than 60 pings in a minute answer
too many pingsand are not stored. - A ping while the monitor is paused answers
pausedand is not stored. - An unknown URL answers
not found. The answer doesn't say which account it belongs to.
When a check fails
Awaiting first ping
Why: No ping yet, and the first window (the interval plus the grace) hasn't passed. Nothing is recorded.
What to change: Call the URL at the end of a run.
No ping yet, or no ping for a while
Why: The window passed with no ping since checks started or since the last ping.
What to change: Check the job runs and that it calls the current URL.
pausedWhy: The monitor is paused, so the ping is not stored.
What to change: Resume the monitor.
too many pingsWhy: More than 60 pings arrived in a minute.
What to change: Ping once per run, not in a loop.
Interval, timeout, pausing and plan limits are on the Shared settings page.