This commit is contained in:
@@ -0,0 +1,58 @@
|
||||
{
|
||||
"uid": "messenger-observability",
|
||||
"title": "Messenger Observability",
|
||||
"schemaVersion": 39,
|
||||
"version": 1,
|
||||
"refresh": "10s",
|
||||
"time": {"from": "now-15m", "to": "now"},
|
||||
"panels": [
|
||||
{
|
||||
"id": 1,
|
||||
"title": "API RPS",
|
||||
"type": "timeseries",
|
||||
"gridPos": {"h": 8, "w": 8, "x": 0, "y": 0},
|
||||
"datasource": {"type": "prometheus", "uid": "Prometheus"},
|
||||
"targets": [{"expr": "sum(rate(messenger_http_requests_total[1m]))","legendFormat":"requests/s"}]
|
||||
},
|
||||
{
|
||||
"id": 2,
|
||||
"title": "API Error Ratio",
|
||||
"type": "timeseries",
|
||||
"gridPos": {"h": 8, "w": 8, "x": 8, "y": 0},
|
||||
"datasource": {"type": "prometheus", "uid": "Prometheus"},
|
||||
"targets": [{"expr": "sum(rate(messenger_http_requests_total{status_class=\"5xx\"}[5m])) / clamp_min(sum(rate(messenger_http_requests_total[5m])), 1)","legendFormat":"5xx/all"}]
|
||||
},
|
||||
{
|
||||
"id": 3,
|
||||
"title": "API Duration p95",
|
||||
"type": "timeseries",
|
||||
"gridPos": {"h": 8, "w": 8, "x": 16, "y": 0},
|
||||
"datasource": {"type": "prometheus", "uid": "Prometheus"},
|
||||
"targets": [{"expr": "histogram_quantile(0.95, sum by (le) (rate(messenger_http_request_duration_seconds_bucket[5m])))","legendFormat":"p95"}]
|
||||
},
|
||||
{
|
||||
"id": 4,
|
||||
"title": "Jobs by Outcome",
|
||||
"type": "timeseries",
|
||||
"gridPos": {"h": 8, "w": 12, "x": 0, "y": 8},
|
||||
"datasource": {"type": "prometheus", "uid": "Prometheus"},
|
||||
"targets": [{"expr": "sum by (outcome) (rate(messenger_jobs_processed_total[5m]))","legendFormat":"{{outcome}}"}]
|
||||
},
|
||||
{
|
||||
"id": 5,
|
||||
"title": "Worker Duration p95",
|
||||
"type": "timeseries",
|
||||
"gridPos": {"h": 8, "w": 12, "x": 12, "y": 8},
|
||||
"datasource": {"type": "prometheus", "uid": "Prometheus"},
|
||||
"targets": [{"expr": "histogram_quantile(0.95, sum by (le) (rate(messenger_job_processing_duration_seconds_bucket[5m])))","legendFormat":"p95"}]
|
||||
},
|
||||
{
|
||||
"id": 6,
|
||||
"title": "Messenger Logs",
|
||||
"type": "logs",
|
||||
"gridPos": {"h": 10, "w": 24, "x": 0, "y": 16},
|
||||
"datasource": {"type": "loki", "uid": "Loki"},
|
||||
"targets": [{"expr": "{service_name=~\"messenger-api|messenger-worker\"}","refId":"A"}]
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,7 @@
|
||||
apiVersion: 1
|
||||
providers:
|
||||
- name: Messenger
|
||||
type: file
|
||||
updateIntervalSeconds: 10
|
||||
options:
|
||||
path: /var/lib/grafana/dashboards
|
||||
@@ -0,0 +1,18 @@
|
||||
apiVersion: 1
|
||||
datasources:
|
||||
- name: Prometheus
|
||||
uid: Prometheus
|
||||
type: prometheus
|
||||
access: proxy
|
||||
url: http://prometheus:9090
|
||||
isDefault: true
|
||||
- name: Loki
|
||||
uid: Loki
|
||||
type: loki
|
||||
access: proxy
|
||||
url: http://loki:3100
|
||||
- name: Tempo
|
||||
uid: Tempo
|
||||
type: tempo
|
||||
access: proxy
|
||||
url: http://tempo:3200
|
||||
Reference in New Issue
Block a user