Historical Anomaly Detector
Objective
Create a historical baseline anomaly detector using the detector wizard and examine the generated alert message.
Step 1 – Create the Detector
Navigate to:
Alerts & Detectors → → Custom Detector
ADD YOUR INITIALS before the proposed detector name.
Naming the detector
It’s important that you add your initials in front of the proposed detector name.
It should be something like this: XYZ’s Advanced Detector.
Configure the following in the alert signal:
- Signal (A):
system.cpu.utilization
- Filter:
deployment.environment : astronomy-shop
, choose Historical Anomaly and then
- Cycle length:
1d - Alert when:
Too high - Trigger Sensitivity:
High
Show advanced settings and review
.
Step 2 – Examine the Default Alert Message
Under Message Preview, click Customize and review the generated message:
What This Message Is Doing
This message uses conditional blocks to render different content depending on whether the detector is triggering or clearing.
{{#if anomalous}}renders content only when the detector is firing.- The
{{else}}branch renders when the detector clears.
This allows one template to handle both trigger and clear notifications.
Important Variables Available in Alert Messages
The following variables are automatically available:
{{ruleName}}– Name of the alert rule{{detectorName}}– Name of the detector{{timestamp}}– Time of the event{{readableRule}}– Human-readable firing condition{{event_annotations.current_window}}– Evaluation window duration{{inputs.summary.value}}– Aggregated metric value for the evaluation window{{inputs.fire_top.value}}– Historical anomaly trigger threshold{{inputs.clear_top.value}}– Historical anomaly clear threshold{{dimensions}}– Dimension key/value pairs (host, environment, etc.){{runbookUrl}}– Configured runbook link (if set){{tip}}– Configured tip (if set){{detectorTags}}– Tags assigned to the detector{{detectorTeams}}– Assigned teams
Any stream that is published in SignalFlow becomes available as:
{{inputs.<stream_name>.value}}
Click to close the custom message.
and do not select anything, we don’t actually want to send notifications for this scenario
When prompted about Missing Alert Notification Policy, choose