Skip to content

Commit 64760fd

Browse files
new doc alert conditions
1 parent 86daf3a commit 64760fd

File tree

3 files changed

+41
-0
lines changed

3 files changed

+41
-0
lines changed

docs/images/alert-conditions.png

117 KB
Loading

docs/user-guide/alerts/.pages

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ nav:
22
- Alerts Overview: index.md
33
- Alerts in OpenObserve: alerts.md
44
- Alert Folders: alert-folders.md
5+
- Alert Conditions: alert-conditions.md
56
- Import and Export Alerts: import-export-alerts.md
67
- Multi-window Selector in Scheduled Alerts (SQL Mode): multi-window-selector-scheduled-alerts-concept.md
78
- Use Multi-window Selector in Scheduled Alerts: multi-window-selector-scheduled-alerts.md
Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
This guide explains how to define alert conditions in OpenObserve using logical operators and grouping rules.
2+
3+
## Define Alert Conditions
4+
While creating an alert, you can define multiple conditions to determine when the alert should be triggered. Use logical operators such as AND and OR to combine conditions. These operators allow you to create structured, rule-based logic to control alert evaluation.
5+
6+
**To define multiple conditions:**
7+
8+
1. In the **Add Alert** view, navigate to the **Conditions** section.
9+
2. Select an operator between AND or OR at the top level. This operator will be applied across all items added at the same level.
10+
3. Define an individual condition using a column, an operator, and a value.
11+
4. Select **+ Condition** to add more conditions at the same level.
12+
5. Select **+ Condition Group** to add a grouped block of conditions. A group has its own operator, independent from the parent group or other groups at the same level.
13+
14+
![Alert conditions](../../images/alert-conditions.png)
15+
16+
## Example
17+
The configuration shown in the image includes the following conditions:
18+
19+
1. The top-level logical operator is `OR`.
20+
2. There are three items at the top level:
21+
22+
- A condition: `k8s_namespace_name` equals `dev3`
23+
- A condition group with the `AND` operator:
24+
25+
- `k8s_cluster` equals `common-dev`
26+
- `k8s_deployment_name` equals `ingress-nginx-controller`
27+
28+
- Another condition group with the `AND` operator:
29+
30+
- `k8s_pod_name` equals `dev3-openobserve-ingester`
31+
- `k8s_deployment_name` equals `dev3-openobserve-router`
32+
33+
## How it works
34+
The alert is triggered if any one of these items is true:
35+
36+
- `k8s_namespace_name` is `dev3`.
37+
- Both `k8s_cluster` is `common-dev` and `k8s_deployment_name` is `ingress-nginx-controller`.
38+
- Both `k8s_pod_name` is `dev3-openobserve-ingester` and `k8s_deployment_name` is `dev3-openobserve-router`.
39+
40+
Because the top-level operator is `OR`, only one item must be true for the alert to trigger.

0 commit comments

Comments
 (0)