1
0

synapse-v2.rules 2.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960
  1. groups:
  2. - name: synapse
  3. rules:
  4. - record: "synapse_federation_transaction_queue_pendingEdus:total"
  5. expr: "sum(synapse_federation_transaction_queue_pendingEdus or absent(synapse_federation_transaction_queue_pendingEdus)*0)"
  6. - record: "synapse_federation_transaction_queue_pendingPdus:total"
  7. expr: "sum(synapse_federation_transaction_queue_pendingPdus or absent(synapse_federation_transaction_queue_pendingPdus)*0)"
  8. - record: 'synapse_http_server_request_count:method'
  9. labels:
  10. servlet: ""
  11. expr: "sum(synapse_http_server_request_count) by (method)"
  12. - record: 'synapse_http_server_request_count:servlet'
  13. labels:
  14. method: ""
  15. expr: 'sum(synapse_http_server_request_count) by (servlet)'
  16. - record: 'synapse_http_server_request_count:total'
  17. labels:
  18. servlet: ""
  19. expr: 'sum(synapse_http_server_request_count:by_method) by (servlet)'
  20. - record: 'synapse_cache:hit_ratio_5m'
  21. expr: 'rate(synapse_util_caches_cache:hits[5m]) / rate(synapse_util_caches_cache:total[5m])'
  22. - record: 'synapse_cache:hit_ratio_30s'
  23. expr: 'rate(synapse_util_caches_cache:hits[30s]) / rate(synapse_util_caches_cache:total[30s])'
  24. - record: 'synapse_federation_client_sent'
  25. labels:
  26. type: "EDU"
  27. expr: 'synapse_federation_client_sent_edus + 0'
  28. - record: 'synapse_federation_client_sent'
  29. labels:
  30. type: "PDU"
  31. expr: 'synapse_federation_client_sent_pdu_destinations:count + 0'
  32. - record: 'synapse_federation_client_sent'
  33. labels:
  34. type: "Query"
  35. expr: 'sum(synapse_federation_client_sent_queries) by (job)'
  36. - record: 'synapse_federation_server_received'
  37. labels:
  38. type: "EDU"
  39. expr: 'synapse_federation_server_received_edus + 0'
  40. - record: 'synapse_federation_server_received'
  41. labels:
  42. type: "PDU"
  43. expr: 'synapse_federation_server_received_pdus + 0'
  44. - record: 'synapse_federation_server_received'
  45. labels:
  46. type: "Query"
  47. expr: 'sum(synapse_federation_server_received_queries) by (job)'
  48. - record: 'synapse_federation_transaction_queue_pending'
  49. labels:
  50. type: "EDU"
  51. expr: 'synapse_federation_transaction_queue_pending_edus + 0'
  52. - record: 'synapse_federation_transaction_queue_pending'
  53. labels:
  54. type: "PDU"
  55. expr: 'synapse_federation_transaction_queue_pending_pdus + 0'