This commit is contained in:
Mateusz Gruszczyński committed 2026-10-05 09:30:21 +02:00
1 parent 1dea7f55c8
commit c819f0a335
151 files changed
+7610 -4264

No files matched your search

+8 -2
View File
@@ -4,7 +4,7 @@
RustProxy Prometheus exporter. It covers global traffic, status classes, vhost
latency, backend health/latency, a dedicated Docker-vhost section, hot/cold/transient
cache memory, Linux process and cgroup diagnostics, HTTP/2/HTTP/3/TLS/WebSocket
counters, Layer-4 streams, structured-log sink health and configuration inventory.
counters, Layer-4 streams, structured-log sink health, configuration inventory and bounded Traffic analytics.
The **Docker vhosts** row uses only the dedicated `rust_proxy_docker_*` metric
families and includes configured/enabled counts, request/error rates, p95 exchange
@@ -12,8 +12,14 @@ latency, backend health/EWMA latency/active work, traffic and probe age. Dashboa
variables **Docker agent** and **Docker service** filter only this section, which keeps
multi-agent installations readable without changing the ordinary vhost panels.
The **Traffic analytics and Web Server** row uses the `rust_proxy_traffic_*` families.
The **Traffic vhost** variable filters that row and exposes Web Server request rate,
serving-source rate, top countries, fixed User-Agent families, HTTP methods, status
classes, cache outcomes, capture-state gauges and configured-route traffic. Raw IP addresses, request paths and full User-Agent strings
are intentionally absent from Prometheus labels.
Import the JSON in Grafana and select a Prometheus datasource when prompted. The
dashboard expects RustProxy 0.18.3 metric names and a scrape interval around 15s.
dashboard expects RustProxy 0.25.5 metric names and a scrape interval around 15s.
Collectors can be disabled in RustProxy settings; panels for disabled collectors
will simply show no series.
+525 -3
View File
@@ -2843,6 +2843,12 @@
"expr": "rust_proxy_acl_profiles_configured",
"legendFormat": "ACL profiles",
"range": true
},
{
"refId": "G",
"expr": "rust_proxy_web_services_configured",
"legendFormat": "web services",
"range": true
}
]
},
@@ -3589,6 +3595,493 @@
],
"title": "Certificate renewal status",
"type": "timeseries"
},
{
"id": 72,
"type": "row",
"title": "Traffic analytics and Web Server",
"collapsed": false,
"gridPos": {
"h": 1,
"w": 24,
"x": 0,
"y": 167
},
"panels": []
},
{
"id": 73,
"type": "stat",
"title": "Web Server request rate",
"datasource": {
"type": "prometheus",
"uid": "${DS_PROMETHEUS}"
},
"gridPos": {
"h": 7,
"w": 6,
"x": 0,
"y": 168
},
"fieldConfig": {
"defaults": {
"unit": "reqps",
"custom": {}
},
"overrides": []
},
"options": {
"reduceOptions": {
"values": false,
"calcs": [
"lastNotNull"
],
"fields": ""
},
"orientation": "auto",
"textMode": "auto",
"colorMode": "value",
"graphMode": "area",
"justifyMode": "auto"
},
"targets": [
{
"refId": "A",
"expr": "sum(rate(rust_proxy_traffic_source_requests_total{vhost=~\"$traffic_vhost\",source=\"web_server\"}[$__rate_interval]))",
"legendFormat": "web server",
"range": true
}
]
},
{
"id": 74,
"type": "stat",
"title": "Traffic samples dropped",
"datasource": {
"type": "prometheus",
"uid": "${DS_PROMETHEUS}"
},
"gridPos": {
"h": 7,
"w": 6,
"x": 6,
"y": 168
},
"fieldConfig": {
"defaults": {
"unit": "short",
"custom": {}
},
"overrides": []
},
"options": {
"reduceOptions": {
"values": false,
"calcs": [
"lastNotNull"
],
"fields": ""
},
"orientation": "auto",
"textMode": "auto",
"colorMode": "value",
"graphMode": "area",
"justifyMode": "auto"
},
"targets": [
{
"refId": "A",
"expr": "rust_proxy_traffic_queue_dropped_total",
"legendFormat": "dropped",
"range": true
}
]
},
{
"id": 75,
"type": "bargauge",
"title": "Top countries",
"datasource": {
"type": "prometheus",
"uid": "${DS_PROMETHEUS}"
},
"gridPos": {
"h": 7,
"w": 6,
"x": 12,
"y": 168
},
"fieldConfig": {
"defaults": {
"unit": "short",
"min": 0,
"custom": {}
},
"overrides": []
},
"options": {
"orientation": "horizontal",
"displayMode": "basic",
"showUnfilled": true,
"reduceOptions": {
"values": false,
"calcs": [
"lastNotNull"
],
"fields": ""
}
},
"targets": [
{
"refId": "A",
"expr": "sum by (country) (rust_proxy_traffic_country_requests{vhost=~\"$traffic_vhost\"})",
"legendFormat": "{{country}}",
"range": false,
"instant": true
}
],
"description": "Bounded Traffic country analytics. Requires country capture in Settings -> Logging; verified Cloudflare uses trusted CF-IPCountry with GeoIP fallback."
},
{
"id": 76,
"type": "bargauge",
"title": "User-Agent families",
"datasource": {
"type": "prometheus",
"uid": "${DS_PROMETHEUS}"
},
"gridPos": {
"h": 7,
"w": 6,
"x": 18,
"y": 168
},
"fieldConfig": {
"defaults": {
"unit": "short",
"min": 0,
"custom": {}
},
"overrides": []
},
"options": {
"orientation": "horizontal",
"displayMode": "basic",
"showUnfilled": true,
"reduceOptions": {
"values": false,
"calcs": [
"lastNotNull"
],
"fields": ""
}
},
"targets": [
{
"refId": "A",
"expr": "sum by (family) (rust_proxy_traffic_user_agent_family_requests_total{vhost=~\"$traffic_vhost\"})",
"legendFormat": "{{family}}",
"range": false,
"instant": true
}
],
"description": "Fixed-cardinality User-Agent families. Full raw User-Agent values are intentionally not exported to Prometheus."
},
{
"id": 77,
"type": "timeseries",
"title": "Requests by serving source",
"datasource": {
"type": "prometheus",
"uid": "${DS_PROMETHEUS}"
},
"gridPos": {
"h": 7,
"w": 12,
"x": 0,
"y": 175
},
"fieldConfig": {
"defaults": {
"unit": "reqps",
"custom": {
"drawStyle": "line",
"lineInterpolation": "linear",
"lineWidth": 1,
"fillOpacity": 10,
"showPoints": "never",
"spanNulls": false,
"axisPlacement": "auto"
}
},
"overrides": []
},
"options": {
"legend": {
"displayMode": "list",
"placement": "bottom",
"calcs": []
},
"tooltip": {
"mode": "multi",
"sort": "none"
}
},
"targets": [
{
"refId": "A",
"expr": "sum by (source) (rate(rust_proxy_traffic_source_requests_total{vhost=~\"$traffic_vhost\"}[$__rate_interval]))",
"legendFormat": "{{source}}",
"range": true
}
]
},
{
"id": 78,
"type": "timeseries",
"title": "Requests by HTTP method",
"datasource": {
"type": "prometheus",
"uid": "${DS_PROMETHEUS}"
},
"gridPos": {
"h": 7,
"w": 12,
"x": 12,
"y": 175
},
"fieldConfig": {
"defaults": {
"unit": "reqps",
"custom": {
"drawStyle": "line",
"lineInterpolation": "linear",
"lineWidth": 1,
"fillOpacity": 10,
"showPoints": "never",
"spanNulls": false,
"axisPlacement": "auto"
}
},
"overrides": []
},
"options": {
"legend": {
"displayMode": "list",
"placement": "bottom",
"calcs": []
},
"tooltip": {
"mode": "multi",
"sort": "none"
}
},
"targets": [
{
"refId": "A",
"expr": "sum by (method) (rate(rust_proxy_traffic_method_requests_total{vhost=~\"$traffic_vhost\"}[$__rate_interval]))",
"legendFormat": "{{method}}",
"range": true
}
]
},
{
"id": 79,
"type": "timeseries",
"title": "Traffic status classes",
"datasource": {
"type": "prometheus",
"uid": "${DS_PROMETHEUS}"
},
"gridPos": {
"h": 7,
"w": 12,
"x": 0,
"y": 182
},
"fieldConfig": {
"defaults": {
"unit": "reqps",
"custom": {
"drawStyle": "line",
"lineInterpolation": "linear",
"lineWidth": 1,
"fillOpacity": 10,
"showPoints": "never",
"spanNulls": false,
"axisPlacement": "auto"
}
},
"overrides": []
},
"options": {
"legend": {
"displayMode": "list",
"placement": "bottom",
"calcs": []
},
"tooltip": {
"mode": "multi",
"sort": "none"
}
},
"targets": [
{
"refId": "A",
"expr": "sum by (class) (rate(rust_proxy_traffic_status_class_requests_total{vhost=~\"$traffic_vhost\"}[$__rate_interval]))",
"legendFormat": "{{class}}",
"range": true
}
]
},
{
"id": 80,
"type": "timeseries",
"title": "Traffic cache outcomes",
"datasource": {
"type": "prometheus",
"uid": "${DS_PROMETHEUS}"
},
"gridPos": {
"h": 7,
"w": 12,
"x": 12,
"y": 182
},
"fieldConfig": {
"defaults": {
"unit": "reqps",
"custom": {
"drawStyle": "line",
"lineInterpolation": "linear",
"lineWidth": 1,
"fillOpacity": 10,
"showPoints": "never",
"spanNulls": false,
"axisPlacement": "auto"
}
},
"overrides": []
},
"options": {
"legend": {
"displayMode": "list",
"placement": "bottom",
"calcs": []
},
"tooltip": {
"mode": "multi",
"sort": "none"
}
},
"targets": [
{
"refId": "A",
"expr": "sum by (cache) (rate(rust_proxy_traffic_cache_requests_total{vhost=~\"$traffic_vhost\"}[$__rate_interval]))",
"legendFormat": "{{cache}}",
"range": true
}
]
},
{
"id": 81,
"type": "stat",
"title": "Traffic capture state",
"datasource": {
"type": "prometheus",
"uid": "${DS_PROMETHEUS}"
},
"gridPos": {
"h": 5,
"w": 12,
"x": 0,
"y": 189
},
"fieldConfig": {
"defaults": {
"unit": "short",
"custom": {},
"min": 0,
"max": 1
},
"overrides": []
},
"options": {
"reduceOptions": {
"values": false,
"calcs": [
"lastNotNull"
],
"fields": ""
},
"orientation": "auto",
"textMode": "auto",
"colorMode": "value",
"graphMode": "area",
"justifyMode": "auto"
},
"targets": [
{
"expr": "rust_proxy_traffic_country_capture_enabled",
"legendFormat": "country capture",
"refId": "A",
"range": false,
"instant": true
},
{
"expr": "rust_proxy_traffic_user_agent_capture_enabled",
"legendFormat": "User-Agent capture",
"refId": "B",
"range": false,
"instant": true
}
],
"description": "Shows whether Traffic country and User-Agent capture are enabled. Country/UA dimension series are populated only when the matching capture setting is enabled."
},
{
"id": 82,
"type": "bargauge",
"title": "Top configured routes",
"datasource": {
"type": "prometheus",
"uid": "${DS_PROMETHEUS}"
},
"gridPos": {
"h": 5,
"w": 12,
"x": 12,
"y": 189
},
"fieldConfig": {
"defaults": {
"unit": "short",
"min": 0,
"custom": {}
},
"overrides": []
},
"options": {
"orientation": "horizontal",
"displayMode": "basic",
"showUnfilled": true,
"reduceOptions": {
"values": false,
"calcs": [
"lastNotNull"
],
"fields": ""
}
},
"targets": [
{
"expr": "sum by (route) (rust_proxy_traffic_route_requests{vhost=~\"$traffic_vhost\"})",
"legendFormat": "{{route}}",
"refId": "A",
"range": false,
"instant": true
}
],
"description": "Approximate bounded Traffic request counts by currently configured route ID. Raw request paths are intentionally not Prometheus labels."
}
],
"refresh": "15s",
@@ -3608,6 +4101,34 @@
"hide": 0,
"refresh": 1
},
{
"name": "traffic_vhost",
"label": "Traffic vhost",
"type": "query",
"datasource": {
"type": "prometheus",
"uid": "${DS_PROMETHEUS}"
},
"query": {
"query": "label_values(rust_proxy_traffic_requests_total, vhost)",
"refId": "StandardVariableQuery"
},
"definition": "label_values(rust_proxy_traffic_requests_total, vhost)",
"current": {
"selected": false,
"text": "All",
"value": "$__all"
},
"hide": 0,
"includeAll": true,
"allValue": ".*",
"multi": true,
"options": [],
"refresh": 1,
"regex": "",
"skipUrlSync": false,
"sort": 1
},
{
"name": "docker_agent",
"label": "Docker agent",
@@ -3672,8 +4193,9 @@
},
"timepicker": {},
"timezone": "browser",
"title": "RustProxy 0.25.4 - Operations",
"title": "RustProxy 0.25.5 - Operations",
"uid": "rustproxy-0170",
"version": 2,
"weekStart": ""
"version": 4,
"weekStart": "",
"description": "RustProxy 0.25.5 operations dashboard including bounded Traffic analytics, country and User-Agent-family visibility, and built-in Web Server traffic."
}