📖 Heartbeat Monitoring Overview
Heartbeat monitoring is a passive monitoring approach. Instead of Monitron reaching out to check your service, your service sends a "ping" to Monitron at regular intervals. If the ping stops coming, Monitron knows something is wrong.
🎯 Perfect For
- ⏰ Cron jobs — Is my nightly backup actually running?
- 📋 Scheduled tasks — Did the daily report generation complete?
- 🔄 Background workers — Is my queue processor still alive?
- 📦 Batch processes — Did the data import finish?
- 🤖 Custom scripts — Anything that runs on a schedule
🔧 工作原理
- Create a Heartbeat monitor in Monitron
- You get a unique URL:
https://your-monitron.com/heartbeat/{token} - Add a ping at the end of your script/job
- Monitron expects a ping every
intervalseconds - If no ping arrives within
interval + grace, Monitron marks it Down
🔗 Two Endpoints
✅ Success Ping
GET or POST https://your-monitron.com/heartbeat/{token}
Call this when your job completes successfully.