mirror of
https://github.com/VictoriaMetrics/VictoriaMetrics.git
synced 2024-12-22 16:36:27 +01:00
9f578e389c
The commit adds a support for template function `query`, `first` and `value`. The function `query` executes a MetricsQL query for active alerts. In vmalert we update templates on every evaluation for active alerts to keep them up to date. With `query` func it may become a perf issue since it will fire a query on every execution. We should keep it in mind for now. https://github.com/VictoriaMetrics/VictoriaMetrics/issues/539
12 lines
248 B
Plaintext
12 lines
248 B
Plaintext
groups:
|
|
- name: group
|
|
rules:
|
|
- alert: UnkownLabelFunction
|
|
for: 5m
|
|
expr: vm_rows > 0
|
|
labels:
|
|
label: bar
|
|
summary: "{{ unknown|query }}"
|
|
annotations:
|
|
description: "{{$labels}}"
|