firing) and recoveries (resolved) to Flashduty On-call. Each alert rule on each monitored target maps to one Flashduty alert: it is created when the rule fires and closed automatically when it resolves.
In Flashduty On-call
Get the push URL in either of two ways.Use a dedicated integration
- In the Flashduty console, select Channels and open a channel
- Select Settings → Integration data → Dedicated integration, then click Add integration
- Select Apache HertzBeat and click Save
- Open the generated integration card and copy the Push URL
Use a shared integration
- In the Flashduty console, go to Integration Center → Alert Events
- Select Apache HertzBeat and enter an integration name
- Set the default route and pick a channel; you can add more rules under Routing after creation
- Click Save and copy the generated Push URL
Configure HertzBeat
1
Add a webhook notice receiver in HertzBeat
Where: HertzBeat › Alerting › Notification › Notice Receiver › New Receiver
Click Send Alert Test Msg. The test button makes Flashduty open an Info alert (see the FAQ below); that alert does not recover, so close it by hand. Then save.
2
Add a notice policy
Where: HertzBeat › Alerting › Notification › Notice Policy › New Notice PolicyA new receiver gets no alerts by itself. Add a policy:
Save it to take effect.
3
Verify the alert lifecycle
Make an alert rule fire (for example, stop a monitored port) and confirm Flashduty receives an active alert. When the rule condition no longer holds, HertzBeat sends a
resolved notification and the Flashduty alert recovers automatically.After a few seconds, go back to Flashduty. If the integration shows a Latest event time, the setup works.Payload
HertzBeat POSTs the default template as JSON. One request can carry several alerts inalerts, and Flashduty handles each one:
commonLabels and commonAnnotations are not read.
Alert key
The HertzBeat payload carries no alert ID. Flashduty builds the Alert Key fromalertname, instance and defineid in alerts[].labels. In real HertzBeat 1.9.0 deliveries these three values were identical on trigger, repeated notification while firing, and recovery, so all three land on one Flashduty alert. Changing the severity, content or monitor name does not change the Alert Key.
A request without labels.alertname is rejected with a parameter error, because a recovery could not be tied to its alert. A missing instance or defineid counts as empty.
Status and severity
A request with any other
status, or an empty alerts, is rejected. In the default template commonLabels.severity is rewritten to decorated text (such as “Critical”), so it is not used for severity.
FAQ
What does Flashduty show after I click Send test message?
What does Flashduty show after I click Send test message?
The button sends a fixed firing request (rule name
CPU Usage Alert, instance 127.0.0.1, content starting with test send msg!). Flashduty returns HTTP 200 and opens a separate Info alert under its own Alert Key, so it never merges into a real alert. No recovery follows; close it by hand in the channel.Does a long-firing alert create duplicates?
Does a long-firing alert create duplicates?
No. HertzBeat resends
firing while the alert stays active. The Alert Key is the same, so Flashduty merges them into one alert.An availability alert did not close in Flashduty after the monitor came back?
An availability alert did not close in Flashduty after the monitor came back?
Flashduty recovers an alert only when HertzBeat sends
resolved. On HertzBeat 1.9.0 an availability alert recovers and sends resolved when the same target comes back up. If you edit the monitor’s host or port while the alert is firing, the alert’s instance label no longer matches any monitor, so the original alert stays firing and sends no resolved. Restore the original target, or close the alert in the HertzBeat alert center.Troubleshooting
- Flashduty receives no alerts: confirm the URL is the full push URL (with
integration_key), a notice policy exists, and the alert matches it - Flashduty returns a parameter error: confirm the body is the default HertzBeat template JSON,
statusisfiringorresolved, and every alert haslabels.alertname - An alert does not recover: confirm HertzBeat sent
resolvedand that itsalertname,instanceanddefineidequal those of the trigger