11groups:
22- name: synapse
33 rules:
4- # These 3 rules are used in the included Prometheus console
4+
5+ ###
6+ ### Prometheus Console Only
7+ ### The following rules are only needed if you use the Prometheus Console
8+ ### in contrib/prometheus/consoles/synapse.html
9+ ###
510 - record: 'synapse_federation_client_sent'
611 labels:
712 type: "EDU"
@@ -15,7 +20,6 @@ groups:
1520 type: "Query"
1621 expr: 'sum(synapse_federation_client_sent_queries) by (job)'
1722
18- # These 3 rules are used in the included Prometheus console
1923 - record: 'synapse_federation_server_received'
2024 labels:
2125 type: "EDU"
@@ -29,7 +33,6 @@ groups:
2933 type: "Query"
3034 expr: 'sum(synapse_federation_server_received_queries) by (job)'
3135
32- # These 2 rules are used in the included Prometheus console
3336 - record: 'synapse_federation_transaction_queue_pending'
3437 labels:
3538 type: "EDU"
@@ -38,8 +41,16 @@ groups:
3841 labels:
3942 type: "PDU"
4043 expr: 'synapse_federation_transaction_queue_pending_pdus + 0'
44+ ###
45+ ### End of 'Prometheus Console Only' rules block
46+ ###
47+
4148
42- # These 3 rules are used in the included Grafana dashboard
49+ ###
50+ ### Grafana Only
51+ ### The following rules are only needed if you use the Grafana dashboard
52+ ### in contrib/grafana/synapse.json
53+ ###
4354 - record: synapse_storage_events_persisted_by_source_type
4455 expr: sum without(type, origin_type, origin_entity) (synapse_storage_events_persisted_events_sep_total{origin_type="remote"})
4556 labels:
@@ -53,11 +64,11 @@ groups:
5364 labels:
5465 type: bridges
5566
56- # This rule is used in the included Grafana dashboard
5767 - record: synapse_storage_events_persisted_by_event_type
5868 expr: sum without(origin_entity, origin_type) (synapse_storage_events_persisted_events_sep_total)
5969
60- # This rule is used in the included Grafana dashboard
6170 - record: synapse_storage_events_persisted_by_origin
6271 expr: sum without(type) (synapse_storage_events_persisted_events_sep_total)
63-
72+ ###
73+ ### End of 'Grafana Only' rules block
74+ ###
0 commit comments