Quick question for people running error workflows in production: how do you catch a polling trigger that just stops?
In a lab test I ran on n8n 2.41.3, a broken RSS trigger produced no execution and no alert in 12 minutes, so the Error Trigger had nothing to respond to. A published error workflow in the same test caught 25 of 25 scheduled failures, but it never fired for silent triggers like this one. I ended up adding an outside heartbeat for missing runs.
What do you use for that — an external monitor, a scheduled check workflow, or something else?
Full tested setup, with the four blind spots and fixes:
2 Likes
Hi @operantsolo, a healthy RSS Trigger also produces no execution when the feed has nothing new, so a heartbeat on missing runs can’t tell a quiet feed from a dead trigger. It either alerts on quiet days or needs a grace period longer than the feed’s longest gap.
Splitting it in two covers both. A second workflow on a Schedule Trigger fetches the feed with an HTTP Request node every hour and compares the newest item’s date with the last one the main workflow saved to a Data Table. If the feed has moved on and the main workflow hasn’t, the trigger is dead, and the check workflow sends the alert. That check workflow also pings an outside heartbeat on every run, so n8n being down shows up as a missed ping.
I use Vivere for that ping (it’s mine), but any external heartbeat with a grace period works.
Thanks, that’s a really useful distinction — a quiet feed and a dead trigger look identical if you only watch for missing runs.
The grace period point is the key one for me: it has to be longer than the feed’s longest gap, otherwise you just get alerts on quiet days. And splitting the check, like you describe — a scheduled workflow that fetches the feed itself and compares the newest item with what the main workflow last saved — is a much better dead-trigger test than a simple heartbeat alone, because it checks whether the feed actually moved.
The outside heartbeat on the check workflow itself is a nice second layer too, for the case where n8n itself is down.
Out of curiosity, how do you usually set that grace period in practice — do you base it on the feed’s history, or just pick a safe multiple of the normal gap?
For the check workflow itself the grace is the easy part, since you control its schedule: 2 to 3 times its own interval (hourly check, alert after about 2.5 hours without a ping) rides out one slow run or a restart.
For the dead-trigger comparison you mostly stop needing a grace based on the feed’s quiet gaps, because you’re comparing against the feed itself. The margin you do need is a race margin: only call the trigger dead when the feed’s newest item is older than the trigger’s poll interval plus some slack (two poll intervals is a reasonable start) and the main workflow still hasn’t saved it. Otherwise you alert on an item the trigger simply hasn’t polled yet.
If you only have the missing-runs heartbeat and no comparison, I’d base it on history rather than a fixed multiple: read the item dates the feed already exposes (most keep somewhere between 10 and 50 entries), take the longest gap, and add headroom. Recheck it now and then, because feeds go quiet over weekends and holidays more than you’d expect.
Thanks all three — this is exactly the gap I was asking about.
The UNIQUE constraint + status pattern makes the claim itself atomic, instead of a lookup-then-write. And minimolo’s one-statement version in n8n is the part I was missing — INSERT … ON CONFLICT DO NOTHING RETURNING, then branch on whether anything came back, and return 2xx for duplicates so the sender stops retrying.
The claimed_at / status timestamp point from williamsj04 is the bit I hadn’t thought through: without it, a crashed execution leaves a claim stuck in processing forever. With it, a retry can take over a stale claim without letting a genuinely in-progress one run twice.
One question for all three: what timeout do you use before you call a processing claim stale — minutes, or do you tie it to how long the downstream work normally takes?
Thanks @TaskToAgent — the race-margin framing is exactly what I was missing. I’m on board with both numbers: a 2–3x check-interval grace for the check workflow itself, and two poll intervals as the starting point for the dead-trigger comparison, so I only call the trigger dead when the feed’s newest item is older than the poll interval plus that slack and the main workflow still hasn’t saved it. One follow-up: does that margin change for long intervals, like a trigger that only polls once a day?