File tree Expand file tree Collapse file tree 3 files changed +9
-4
lines changed Expand file tree Collapse file tree 3 files changed +9
-4
lines changed Original file line number Diff line number Diff line change 66- name: rabbitmq.rules
77 rules:
88 - alert: RabbitMQNodeDown
9- expr: sum(rabbitmq_build_info{instance!=""}) < {{ groups['rabbitmq'] | length } }
9+ expr: sum(rabbitmq_build_info{instance!=""}) < {% endraw %}{{ alertmanager_number_of_rabbitmq_nodes }}{% raw % }
1010 for: 30m
1111 labels:
1212 severity: critical
Original file line number Diff line number Diff line change @@ -26,6 +26,9 @@ alertmanager_packet_drop_threshold: 1
2626# packets/s averaged over 5 minutes.
2727alertmanager_packet_errors_threshold : 1
2828
29+ # Number of RabbitMQ nodes in the cluster.
30+ alertmanager_number_of_rabbitmq_nodes : " {{ groups['controllers'] | length }}"
31+
2932# ##############################################################################
3033# Exporter configuration
3134
Original file line number Diff line number Diff line change 11---
22features :
33 - |
4- Use the length of the ``rabbitmq`` group to determine if any RabbitMQ
5- nodes are down. This is benefical for deployments that do not use a
6- standard three node setup.
4+ Allow for easy customisation of the number of expected `RabbitMQ`
5+ nodes when evaluating the alert `RabbitMQNodeDown`. It is set by
6+ the `alertmanager_number_of_rabbitmq_nodes` which defaults to the
7+ number of `controllers`. This is benefical for deployments that
8+ do not use a standard three node setup.
You can’t perform that action at this time.
0 commit comments