summaryrefslogtreecommitdiff
path: root/monitoring/grafana/dashboards/trading-overview.json
diff options
context:
space:
mode:
Diffstat (limited to 'monitoring/grafana/dashboards/trading-overview.json')
-rw-r--r--monitoring/grafana/dashboards/trading-overview.json297
1 files changed, 297 insertions, 0 deletions
diff --git a/monitoring/grafana/dashboards/trading-overview.json b/monitoring/grafana/dashboards/trading-overview.json
new file mode 100644
index 0000000..ff7f8ff
--- /dev/null
+++ b/monitoring/grafana/dashboards/trading-overview.json
@@ -0,0 +1,297 @@
+{
+ "uid": "trading-overview",
+ "title": "Trading Platform Overview",
+ "tags": ["trading"],
+ "timezone": "browser",
+ "schemaVersion": 39,
+ "version": 1,
+ "refresh": "10s",
+ "time": {
+ "from": "now-1h",
+ "to": "now"
+ },
+ "panels": [
+ {
+ "type": "row",
+ "id": 1,
+ "title": "Service Health",
+ "gridPos": { "h": 1, "w": 24, "x": 0, "y": 0 },
+ "collapsed": false,
+ "panels": []
+ },
+ {
+ "type": "stat",
+ "id": 2,
+ "title": "Services Up",
+ "gridPos": { "h": 6, "w": 12, "x": 0, "y": 1 },
+ "datasource": { "type": "prometheus", "uid": "prometheus" },
+ "targets": [
+ {
+ "expr": "sum(data_collector_up == 1) + sum(strategy_engine_up == 1) + sum(order_executor_up == 1) + sum(portfolio_manager_up == 1)",
+ "legendFormat": "Services Up",
+ "refId": "A"
+ }
+ ],
+ "fieldConfig": {
+ "defaults": {
+ "thresholds": {
+ "mode": "absolute",
+ "steps": [
+ { "color": "red", "value": null },
+ { "color": "yellow", "value": 2 },
+ { "color": "green", "value": 4 }
+ ]
+ },
+ "unit": "none",
+ "min": 0,
+ "max": 4
+ },
+ "overrides": []
+ },
+ "options": {
+ "reduceOptions": {
+ "calcs": ["lastNotNull"],
+ "fields": "",
+ "values": false
+ },
+ "orientation": "auto",
+ "textMode": "auto",
+ "colorMode": "value",
+ "graphMode": "none"
+ }
+ },
+ {
+ "type": "timeseries",
+ "id": 3,
+ "title": "Error Rate",
+ "gridPos": { "h": 6, "w": 12, "x": 12, "y": 1 },
+ "datasource": { "type": "prometheus", "uid": "prometheus" },
+ "targets": [
+ {
+ "expr": "sum(rate(data_collector_errors_total[5m]))",
+ "legendFormat": "data-collector",
+ "refId": "A"
+ },
+ {
+ "expr": "sum(rate(strategy_engine_errors_total[5m]))",
+ "legendFormat": "strategy-engine",
+ "refId": "B"
+ },
+ {
+ "expr": "sum(rate(order_executor_errors_total[5m]))",
+ "legendFormat": "order-executor",
+ "refId": "C"
+ },
+ {
+ "expr": "sum(rate(portfolio_manager_errors_total[5m]))",
+ "legendFormat": "portfolio-manager",
+ "refId": "D"
+ }
+ ],
+ "fieldConfig": {
+ "defaults": {
+ "custom": {
+ "drawStyle": "line",
+ "lineInterpolation": "smooth",
+ "fillOpacity": 10,
+ "pointSize": 5,
+ "showPoints": "auto"
+ },
+ "unit": "ops"
+ },
+ "overrides": []
+ },
+ "options": {
+ "tooltip": { "mode": "multi", "sort": "desc" },
+ "legend": { "displayMode": "table", "placement": "bottom" }
+ }
+ },
+ {
+ "type": "row",
+ "id": 4,
+ "title": "Trading Activity",
+ "gridPos": { "h": 1, "w": 24, "x": 0, "y": 7 },
+ "collapsed": false,
+ "panels": []
+ },
+ {
+ "type": "timeseries",
+ "id": 5,
+ "title": "Signals Generated",
+ "gridPos": { "h": 6, "w": 12, "x": 0, "y": 8 },
+ "datasource": { "type": "prometheus", "uid": "prometheus" },
+ "targets": [
+ {
+ "expr": "rate(strategy_engine_events_processed_total[5m])",
+ "legendFormat": "{{ job }}",
+ "refId": "A"
+ }
+ ],
+ "fieldConfig": {
+ "defaults": {
+ "custom": {
+ "drawStyle": "line",
+ "lineInterpolation": "smooth",
+ "fillOpacity": 10,
+ "pointSize": 5,
+ "showPoints": "auto"
+ },
+ "unit": "ops"
+ },
+ "overrides": []
+ },
+ "options": {
+ "tooltip": { "mode": "single", "sort": "none" },
+ "legend": { "displayMode": "list", "placement": "bottom" }
+ }
+ },
+ {
+ "type": "timeseries",
+ "id": 6,
+ "title": "Orders Executed",
+ "gridPos": { "h": 6, "w": 12, "x": 12, "y": 8 },
+ "datasource": { "type": "prometheus", "uid": "prometheus" },
+ "targets": [
+ {
+ "expr": "rate(order_executor_events_processed_total[5m])",
+ "legendFormat": "{{ job }}",
+ "refId": "A"
+ }
+ ],
+ "fieldConfig": {
+ "defaults": {
+ "custom": {
+ "drawStyle": "line",
+ "lineInterpolation": "smooth",
+ "fillOpacity": 10,
+ "pointSize": 5,
+ "showPoints": "auto"
+ },
+ "unit": "ops"
+ },
+ "overrides": []
+ },
+ "options": {
+ "tooltip": { "mode": "single", "sort": "none" },
+ "legend": { "displayMode": "list", "placement": "bottom" }
+ }
+ },
+ {
+ "type": "row",
+ "id": 7,
+ "title": "Data Collection",
+ "gridPos": { "h": 1, "w": 24, "x": 0, "y": 14 },
+ "collapsed": false,
+ "panels": []
+ },
+ {
+ "type": "timeseries",
+ "id": 8,
+ "title": "Candles Received",
+ "gridPos": { "h": 6, "w": 12, "x": 0, "y": 15 },
+ "datasource": { "type": "prometheus", "uid": "prometheus" },
+ "targets": [
+ {
+ "expr": "rate(data_collector_events_processed_total[5m])",
+ "legendFormat": "{{ job }}",
+ "refId": "A"
+ }
+ ],
+ "fieldConfig": {
+ "defaults": {
+ "custom": {
+ "drawStyle": "line",
+ "lineInterpolation": "smooth",
+ "fillOpacity": 10,
+ "pointSize": 5,
+ "showPoints": "auto"
+ },
+ "unit": "ops"
+ },
+ "overrides": []
+ },
+ "options": {
+ "tooltip": { "mode": "single", "sort": "none" },
+ "legend": { "displayMode": "list", "placement": "bottom" }
+ }
+ },
+ {
+ "type": "timeseries",
+ "id": 9,
+ "title": "WebSocket Reconnections",
+ "gridPos": { "h": 6, "w": 12, "x": 12, "y": 15 },
+ "datasource": { "type": "prometheus", "uid": "prometheus" },
+ "targets": [
+ {
+ "expr": "data_collector_errors_total{error_type=\"reconnect\"}",
+ "legendFormat": "reconnections",
+ "refId": "A"
+ }
+ ],
+ "fieldConfig": {
+ "defaults": {
+ "custom": {
+ "drawStyle": "line",
+ "lineInterpolation": "stepAfter",
+ "fillOpacity": 10,
+ "pointSize": 5,
+ "showPoints": "auto"
+ },
+ "unit": "short"
+ },
+ "overrides": []
+ },
+ "options": {
+ "tooltip": { "mode": "single", "sort": "none" },
+ "legend": { "displayMode": "list", "placement": "bottom" }
+ }
+ },
+ {
+ "type": "row",
+ "id": 10,
+ "title": "Portfolio",
+ "gridPos": { "h": 1, "w": 24, "x": 0, "y": 21 },
+ "collapsed": false,
+ "panels": []
+ },
+ {
+ "type": "gauge",
+ "id": 11,
+ "title": "Portfolio Value",
+ "gridPos": { "h": 6, "w": 12, "x": 0, "y": 22 },
+ "datasource": { "type": "prometheus", "uid": "prometheus" },
+ "targets": [
+ {
+ "expr": "portfolio_manager_portfolio_value",
+ "legendFormat": "Portfolio Value",
+ "refId": "A"
+ }
+ ],
+ "fieldConfig": {
+ "defaults": {
+ "thresholds": {
+ "mode": "absolute",
+ "steps": [
+ { "color": "red", "value": null },
+ { "color": "yellow", "value": 1000 },
+ { "color": "green", "value": 10000 }
+ ]
+ },
+ "unit": "currencyUSD",
+ "min": 0
+ },
+ "overrides": []
+ },
+ "options": {
+ "reduceOptions": {
+ "calcs": ["lastNotNull"],
+ "fields": "",
+ "values": false
+ },
+ "showThresholdLabels": false,
+ "showThresholdMarkers": true,
+ "orientation": "auto"
+ }
+ }
+ ]
+}