Pull checks vs. push heartbeats (dead man's switch) — which for cron jobs?
Q: How do I monitor a nightly backup that has no public URL?
A: Pull-based checks don't work here — there's nothing for the monitor to hit. Use a push heartbeat, also called a dead man's switch. Your job sends an HTTP ping to a unique URL when it finishes. If the monitor doesn't hear from it within the expected window, it alerts. No news is bad news, by design.
Pull is right for anything with a public endpoint (websites, APIs). Push is right for background jobs, cron tasks, queue workers, IoT devices — anything behind a firewall or with no inbound URL.
The upgrade most people miss: send the ping only on success, and have the script pass a start ping too, so a job that hangs halfway also trips the alert instead of just a job that never started.
Got a question? Drop it in the comments.
Pingback Clinic
@PingbackClinic
Pull checks vs. push heartbeats (dead man's switch) — which for cron jobs?
Этот пост опубликован в Telegram-канале Pingback Clinic. Подписаться можно по ссылке: @PingbackClinic.