diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 405463e2f751..7321b3b6f2f5 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -53,7 +53,7 @@ jobs: # Misc sanity checks - name: Lint Grafana dashboards - run: node scripts/validate-grafana-dashboard.mjs ./dashboards + run: scripts/validate-grafana-dashboards.sh - name: Test root binary exists run: ./lodestar --version - name: Reject yarn.lock changes diff --git a/dashboards/libp2p.json b/dashboards/libp2p.json index 374dcbe3c272..66b2f346b5b7 100644 --- a/dashboards/libp2p.json +++ b/dashboards/libp2p.json @@ -60,7 +60,9 @@ "icon": "external link", "includeVars": true, "keepTime": true, - "tags": ["lodestar"], + "tags": [ + "lodestar" + ], "targetBlank": false, "title": "Lodestar dashboards", "tooltip": "", @@ -684,10 +686,12 @@ "type": "timeseries" } ], - "refresh": "30s", + "refresh": "10s", "schemaVersion": 35, "style": "dark", - "tags": ["lodestar"], + "tags": [ + "lodestar" + ], "templating": { "list": [ { @@ -703,6 +707,7 @@ "name": "DS_PROMETHEUS", "options": [], "query": "prometheus", + "queryValue": "", "refresh": 1, "regex": "", "skipUrlSync": false, @@ -714,8 +719,8 @@ "auto_min": "10s", "current": { "selected": false, - "text": "auto", - "value": "$__auto_interval_rate_interval" + "text": "1h", + "value": "1h" }, "hide": 0, "label": "rate() interval", @@ -737,12 +742,12 @@ "value": "10m" }, { - "selected": true, + "selected": false, "text": "30m", "value": "30m" }, { - "selected": false, + "selected": true, "text": "1h", "value": "1h" }, @@ -807,10 +812,23 @@ "from": "now-24h", "to": "now" }, - "timepicker": {}, - "timezone": "", + "timepicker": { + "refresh_intervals": [ + "5s", + "10s", + "30s", + "1m", + "5m", + "15m", + "30m", + "1h", + "2h", + "1d" + ] + }, + "timezone": "utc", "title": "Libp2p", "uid": "C5u1rHZVk", "version": 6, - "weekStart": "" + "weekStart": "monday" } diff --git a/dashboards/lodestar_block_processor.json b/dashboards/lodestar_block_processor.json index 92a703e81402..8599cba06de7 100644 --- a/dashboards/lodestar_block_processor.json +++ b/dashboards/lodestar_block_processor.json @@ -66,7 +66,9 @@ "icon": "external link", "includeVars": true, "keepTime": true, - "tags": ["lodestar"], + "tags": [ + "lodestar" + ], "targetBlank": false, "title": "Lodestar dashboards", "tooltip": "", @@ -3066,7 +3068,9 @@ "refresh": "10s", "schemaVersion": 35, "style": "dark", - "tags": ["lodestar"], + "tags": [ + "lodestar" + ], "templating": { "list": [ { @@ -3094,8 +3098,8 @@ "auto_min": "10s", "current": { "selected": false, - "text": "30m", - "value": "30m" + "text": "1h", + "value": "1h" }, "hide": 0, "label": "rate() interval", @@ -3117,12 +3121,12 @@ "value": "10m" }, { - "selected": true, + "selected": false, "text": "30m", "value": "30m" }, { - "selected": false, + "selected": true, "text": "1h", "value": "1h" }, @@ -3188,11 +3192,22 @@ "to": "now" }, "timepicker": { - "refresh_intervals": ["5s", "10s", "30s", "1m", "5m", "15m", "30m", "1h", "2h", "1d"] + "refresh_intervals": [ + "5s", + "10s", + "30s", + "1m", + "5m", + "15m", + "30m", + "1h", + "2h", + "1d" + ] }, - "timezone": "", + "timezone": "utc", "title": "Lodestar - block processor", "uid": "lodestar_block_processor", "version": 2, - "weekStart": "" + "weekStart": "monday" } diff --git a/dashboards/lodestar_block_production.json b/dashboards/lodestar_block_production.json index 6888ea11475c..987612a71f07 100644 --- a/dashboards/lodestar_block_production.json +++ b/dashboards/lodestar_block_production.json @@ -61,7 +61,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "refId": "A" } @@ -436,7 +436,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "editorMode": "code", "expr": "rate(lodestar_api_rest_errors_total{operationId=~\"produceBlockV2|produceBlindedBlock|publishBlock|publishBlindedBlock\"}[$rate_interval])", @@ -1036,7 +1036,7 @@ "condition": "", "key": "instance", "operator": "=", - "value": "hetzner-lido-prod-bn-1" + "value": "unstable-lg1k-hzax41" } ], "hide": 0, @@ -1064,9 +1064,9 @@ "1d" ] }, - "timezone": "", + "timezone": "utc", "title": "Lodestar - block production", "uid": "lodestar_block_production", "version": 5, - "weekStart": "" -} \ No newline at end of file + "weekStart": "monday" +} diff --git a/dashboards/lodestar_bls_thread_pool.json b/dashboards/lodestar_bls_thread_pool.json index ba3064ea40e2..622126f17c4b 100644 --- a/dashboards/lodestar_bls_thread_pool.json +++ b/dashboards/lodestar_bls_thread_pool.json @@ -66,7 +66,9 @@ "icon": "external link", "includeVars": true, "keepTime": true, - "tags": ["lodestar"], + "tags": [ + "lodestar" + ], "targetBlank": false, "title": "Lodestar dashboards", "tooltip": "", @@ -1114,7 +1116,9 @@ "refresh": "10s", "schemaVersion": 35, "style": "dark", - "tags": ["lodestar"], + "tags": [ + "lodestar" + ], "templating": { "list": [ { @@ -1142,8 +1146,8 @@ "auto_min": "10s", "current": { "selected": false, - "text": "30m", - "value": "30m" + "text": "1h", + "value": "1h" }, "hide": 0, "label": "rate() interval", @@ -1165,12 +1169,12 @@ "value": "10m" }, { - "selected": true, + "selected": false, "text": "30m", "value": "30m" }, { - "selected": false, + "selected": true, "text": "1h", "value": "1h" }, @@ -1236,11 +1240,22 @@ "to": "now" }, "timepicker": { - "refresh_intervals": ["5s", "10s", "30s", "1m", "5m", "15m", "30m", "1h", "2h", "1d"] + "refresh_intervals": [ + "5s", + "10s", + "30s", + "1m", + "5m", + "15m", + "30m", + "1h", + "2h", + "1d" + ] }, - "timezone": "", + "timezone": "utc", "title": "Lodestar - BLS thread pool", "uid": "lodestar_bls_thread_pool", "version": 2, - "weekStart": "" + "weekStart": "monday" } diff --git a/dashboards/lodestar_debug_gossipsub.json b/dashboards/lodestar_debug_gossipsub.json index 8a7ed6eaa123..ef0853ae5917 100644 --- a/dashboards/lodestar_debug_gossipsub.json +++ b/dashboards/lodestar_debug_gossipsub.json @@ -78,7 +78,9 @@ "icon": "external link", "includeVars": true, "keepTime": true, - "tags": ["lodestar"], + "tags": [ + "lodestar" + ], "targetBlank": false, "title": "Lodestar dashboards", "tooltip": "", @@ -213,7 +215,9 @@ "justifyMode": "auto", "orientation": "auto", "reduceOptions": { - "calcs": ["lastNotNull"], + "calcs": [ + "lastNotNull" + ], "fields": "", "values": false }, @@ -281,7 +285,9 @@ "justifyMode": "auto", "orientation": "auto", "reduceOptions": { - "calcs": ["lastNotNull"], + "calcs": [ + "lastNotNull" + ], "fields": "", "values": false }, @@ -336,7 +342,9 @@ "justifyMode": "auto", "orientation": "auto", "reduceOptions": { - "calcs": ["lastNotNull"], + "calcs": [ + "lastNotNull" + ], "fields": "", "values": false }, @@ -385,7 +393,9 @@ "justifyMode": "auto", "orientation": "auto", "reduceOptions": { - "calcs": ["lastNotNull"], + "calcs": [ + "lastNotNull" + ], "fields": "", "values": false }, @@ -443,7 +453,9 @@ "justifyMode": "auto", "orientation": "auto", "reduceOptions": { - "calcs": ["lastNotNull"], + "calcs": [ + "lastNotNull" + ], "fields": "", "values": false }, @@ -8584,7 +8596,10 @@ "refresh": "10s", "schemaVersion": 35, "style": "dark", - "tags": ["lodestar", "debug"], + "tags": [ + "lodestar", + "debug" + ], "templating": { "list": [ { @@ -8611,9 +8626,9 @@ "auto_count": 30, "auto_min": "10s", "current": { - "selected": true, - "text": "6h", - "value": "6h" + "selected": false, + "text": "1h", + "value": "1h" }, "hide": 0, "label": "rate() interval", @@ -8640,12 +8655,12 @@ "value": "30m" }, { - "selected": false, + "selected": true, "text": "1h", "value": "1h" }, { - "selected": true, + "selected": false, "text": "6h", "value": "6h" }, @@ -8706,11 +8721,22 @@ "to": "now" }, "timepicker": { - "refresh_intervals": ["5s", "10s", "30s", "1m", "5m", "15m", "30m", "1h", "2h", "1d"] + "refresh_intervals": [ + "5s", + "10s", + "30s", + "1m", + "5m", + "15m", + "30m", + "1h", + "2h", + "1d" + ] }, - "timezone": "", + "timezone": "utc", "title": "Lodestar - debug gossipsub", "uid": "lodestar_debug_gossipsub", "version": 1, - "weekStart": "" + "weekStart": "monday" } diff --git a/dashboards/lodestar_discv5.json b/dashboards/lodestar_discv5.json index 817f7681c0ca..0bb863631847 100644 --- a/dashboards/lodestar_discv5.json +++ b/dashboards/lodestar_discv5.json @@ -140,7 +140,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "rate(lodestar_discovery_discovered_status_total_count[$rate_interval])", @@ -235,7 +235,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "expr": "lodestar_discv5_connected_peer_count", "interval": "", @@ -329,7 +329,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "sum(lodestar_discovery_dial_time_seconds_count{status=\"error\"})/sum(lodestar_discovery_dial_time_seconds_count)", @@ -424,7 +424,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "rate(lodestar_discovery_total_dial_attempts[$rate_interval])", @@ -519,7 +519,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "expr": "rate(lodestar_discv5_sent_message_count[$rate_interval])", "interval": "", @@ -613,7 +613,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "expr": "rate(lodestar_discv5_rcvd_message_count[$rate_interval])", "interval": "", @@ -812,7 +812,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "rate(lodestar_discovery_find_node_query_time_seconds_sum[$rate_interval])/rate(lodestar_discovery_find_node_query_time_seconds_count[$rate_interval])", @@ -906,7 +906,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "lodestar_discv5_kad_table_size", @@ -1000,7 +1000,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "expr": "lodestar_discv5_active_session_count", "interval": "", @@ -1093,7 +1093,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "sum(rate(lodestar_discovery_discovered_status_total_count{status=~\"attempt_dial|cached\"}[$rate_interval]))\n/\nsum(rate(lodestar_discovery_discovered_status_total_count{status=~\"dropped|attempt_dial|cached\"}[$rate_interval]))", @@ -1187,7 +1187,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "lodestar_discovery_cached_enrs_size", @@ -1281,7 +1281,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "sum(rate(lodestar_discovery_discovered_status_total_count{status=~\"dropped|attempt_dial|cached\"}[$rate_interval]))\n/\nsum(rate(lodestar_discovery_discovered_status_total_count[$rate_interval]))", @@ -1407,7 +1407,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "rate(lodestar_discovery_dial_time_seconds_sum[$rate_interval])/rate(lodestar_discovery_dial_time_seconds_count[$rate_interval])", @@ -1607,7 +1607,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "editorMode": "builder", "expr": "discv5_worker_nodejs_heap_space_size_used_bytes", @@ -1618,7 +1618,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "editorMode": "builder", "expr": "discv5_worker_nodejs_external_memory_bytes", @@ -1712,7 +1712,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "editorMode": "builder", "expr": "rate(discv5_worker_nodejs_gc_duration_seconds_sum[$__rate_interval])", @@ -1804,7 +1804,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "editorMode": "builder", "expr": "discv5_worker_nodejs_active_resources", @@ -1897,7 +1897,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "editorMode": "builder", "expr": "discv5_worker_nodejs_eventloop_lag_seconds", @@ -1989,7 +1989,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "editorMode": "builder", "expr": "discv5_worker_nodejs_active_handles", @@ -2260,6 +2260,7 @@ "name": "DS_PROMETHEUS", "options": [], "query": "prometheus", + "queryValue": "", "refresh": 1, "regex": "", "skipUrlSync": false, @@ -2335,6 +2336,7 @@ } ], "query": "1m,10m,30m,1h,6h,12h,1d,7d,14d,30d", + "queryValue": "", "refresh": 2, "skipUrlSync": false, "type": "interval" @@ -2349,7 +2351,7 @@ "condition": "", "key": "instance", "operator": "=", - "value": "beta-lg1k-hzax41" + "value": "unstable-lg1k-hzax41" } ], "hide": 0, @@ -2360,13 +2362,26 @@ ] }, "time": { - "from": "now-6h", + "from": "now-24h", "to": "now" }, - "timepicker": {}, - "timezone": "", + "timepicker": { + "refresh_intervals": [ + "5s", + "10s", + "30s", + "1m", + "5m", + "15m", + "30m", + "1h", + "2h", + "1d" + ] + }, + "timezone": "utc", "title": "Lodestar - discv5", "uid": "lodestar_discv5", "version": 7, - "weekStart": "" -} \ No newline at end of file + "weekStart": "monday" +} diff --git a/dashboards/lodestar_execution_engine.json b/dashboards/lodestar_execution_engine.json index c7399f23ddef..ac60eb23dab5 100644 --- a/dashboards/lodestar_execution_engine.json +++ b/dashboards/lodestar_execution_engine.json @@ -61,7 +61,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "refId": "A" } @@ -151,7 +151,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "rate(lodestar_engine_http_processor_queue_job_time_seconds_sum[$rate_interval])", @@ -248,7 +248,7 @@ { "datasource": { "type": "prometheus", - "uid": "Prometheus" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "12*rate(lodestar_engine_http_processor_queue_job_time_seconds_count[6m])", @@ -345,7 +345,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "delta(lodestar_engine_http_processor_queue_job_time_seconds_sum[$rate_interval])/delta(lodestar_engine_http_processor_queue_job_time_seconds_count[$rate_interval])", @@ -442,7 +442,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "delta(lodestar_engine_http_processor_queue_dropped_jobs_total[$rate_interval])/(delta(lodestar_engine_http_processor_queue_job_time_seconds_count[$rate_interval])+delta(lodestar_engine_http_processor_queue_dropped_jobs_total[$rate_interval]))", @@ -539,7 +539,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "delta(lodestar_engine_http_processor_queue_job_wait_time_seconds_sum[$rate_interval])/delta(lodestar_engine_http_processor_queue_job_wait_time_seconds_count[$rate_interval])", @@ -636,7 +636,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "lodestar_engine_http_processor_queue_length", @@ -667,7 +667,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "refId": "A" } @@ -758,7 +758,7 @@ { "datasource": { "type": "prometheus", - "uid": "Prometheus" + "uid": "${DS_PROMETHEUS}" }, "editorMode": "code", "exemplar": false, @@ -820,7 +820,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "lodestar_execution_engine_http_client_config_urls_count", @@ -916,7 +916,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "lodestar_execution_engine_http_client_active_requests", @@ -1012,7 +1012,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "rate(lodestar_execution_engine_http_client_request_retries_total[$rate_interval])", @@ -1108,7 +1108,7 @@ { "datasource": { "type": "prometheus", - "uid": "Prometheus" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "rate(lodestar_execution_engine_http_client_request_time_seconds_sum[32m])\n/\nrate(lodestar_execution_engine_http_client_request_time_seconds_count[32m])", @@ -1205,7 +1205,7 @@ { "datasource": { "type": "prometheus", - "uid": "Prometheus" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "rate(lodestar_execution_engine_http_client_request_errors_total[$rate_interval])", @@ -1217,7 +1217,7 @@ { "datasource": { "type": "prometheus", - "uid": "Prometheus" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "rate(lodestar_execution_engine_http_client_request_used_fallback_url_total[$rate_interval])", @@ -1311,7 +1311,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "1 - sum(rate(lodestar_execution_engine_http_client_request_time_seconds_bucket{le=\"1\"}[32m])) by (routeId) / sum(rate(lodestar_execution_engine_http_client_request_time_seconds_count[32m])) by (routeId)", @@ -1403,7 +1403,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "editorMode": "builder", "expr": "rate(lodestar_execution_engine_notify_new_payload_result_total[1h])", @@ -1433,7 +1433,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "refId": "A" } @@ -1524,7 +1524,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "lodestar_eth1_remote_highest_block", @@ -1536,7 +1536,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "lodestar_eth1_last_processed_deposit_block_number", @@ -1548,7 +1548,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "lodestar_eth1_last_fetched_block_block_number", @@ -1623,7 +1623,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "lodestar_eth1_deposit_tracker_is_caughtup", @@ -1682,7 +1682,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "lodestar_eth1_http_client_config_urls_count", @@ -1743,7 +1743,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "lodestar_eth1_follow_distance_seconds_config", @@ -1804,7 +1804,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "lodestar_eth1_last_fetched_block_timestamp", @@ -1902,7 +1902,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "lodestar_eth1_follow_distance_dynamic", @@ -1914,7 +1914,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "lodestar_eth1_blocks_batch_size_dynamic", @@ -1926,7 +1926,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "lodestar_eth1_logs_batch_size_dynamic", @@ -2022,7 +2022,7 @@ { "datasource": { "type": "prometheus", - "uid": "Prometheus" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "rate(lodestar_eth1_http_client_request_time_seconds_sum[32m])/rate(lodestar_eth1_http_client_request_time_seconds_count[32m])", @@ -2119,7 +2119,7 @@ { "datasource": { "type": "prometheus", - "uid": "Prometheus" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "lodestar_eth1_http_client_request_errors_total", @@ -2130,7 +2130,7 @@ { "datasource": { "type": "prometheus", - "uid": "Prometheus" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "rate(lodestar_eth1_deposit_tracker_update_errors_total[$rate_interval])", @@ -2142,7 +2142,7 @@ { "datasource": { "type": "prometheus", - "uid": "Prometheus" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "rate(lodestar_eth1_http_client_request_used_fallback_url_total[$rate_interval])", @@ -2235,7 +2235,7 @@ { "datasource": { "type": "prometheus", - "uid": "Prometheus" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "12*rate(lodestar_eth1_http_client_request_time_seconds_count[32m])", @@ -2327,7 +2327,7 @@ { "datasource": { "type": "prometheus", - "uid": "Prometheus" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "rate(lodestar_eth1_blocks_fetched_total[32m])", @@ -2339,7 +2339,7 @@ { "datasource": { "type": "prometheus", - "uid": "Prometheus" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "rate(lodestar_eth1_deposit_events_fetched_total[32m])", @@ -3409,7 +3409,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "refId": "A" } @@ -3451,8 +3451,8 @@ "auto_min": "10s", "current": { "selected": false, - "text": "30m", - "value": "30m" + "text": "1h", + "value": "1h" }, "hide": 0, "label": "rate() interval", @@ -3474,12 +3474,12 @@ "value": "10m" }, { - "selected": true, + "selected": false, "text": "30m", "value": "30m" }, { - "selected": false, + "selected": true, "text": "1h", "value": "1h" }, @@ -3530,7 +3530,7 @@ "condition": "", "key": "instance", "operator": "=", - "value": "nogroup-ctvpss-0" + "value": "unstable-lg1k-hzax41" } ], "hide": 0, @@ -3558,9 +3558,9 @@ "1d" ] }, - "timezone": "", + "timezone": "utc", "title": "Lodestar - execution engine", "uid": "lodestar_execution_engine", "version": 7, - "weekStart": "" -} \ No newline at end of file + "weekStart": "monday" +} diff --git a/dashboards/lodestar_multinode.json b/dashboards/lodestar_multinode.json index 9610ef31b511..52a2c7b7ed76 100644 --- a/dashboards/lodestar_multinode.json +++ b/dashboards/lodestar_multinode.json @@ -28,7 +28,9 @@ "icon": "external link", "includeVars": true, "keepTime": true, - "tags": ["lodestar"], + "tags": [ + "lodestar" + ], "targetBlank": false, "title": "Lodestar dashboards", "tooltip": "", @@ -90,7 +92,9 @@ "justifyMode": "auto", "orientation": "auto", "reduceOptions": { - "calcs": ["lastNotNull"], + "calcs": [ + "lastNotNull" + ], "fields": "", "values": false }, @@ -104,7 +108,7 @@ { "datasource": { "type": "prometheus", - "uid": "PBFA97CFB590B2093" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "up", @@ -189,7 +193,7 @@ { "datasource": { "type": "prometheus", - "uid": "PBFA97CFB590B2093" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "beacon_head_slot", @@ -273,7 +277,7 @@ { "datasource": { "type": "prometheus", - "uid": "PBFA97CFB590B2093" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "libp2p_peers", @@ -358,7 +362,7 @@ { "datasource": { "type": "prometheus", - "uid": "PBFA97CFB590B2093" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "process_heap_bytes", @@ -444,7 +448,7 @@ { "datasource": { "type": "prometheus", - "uid": "PBFA97CFB590B2093" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "rate(process_cpu_seconds_total[$__rate_interval])", @@ -489,7 +493,9 @@ "justifyMode": "auto", "orientation": "auto", "reduceOptions": { - "calcs": ["lastNotNull"], + "calcs": [ + "lastNotNull" + ], "fields": "", "values": false }, @@ -504,7 +510,7 @@ { "datasource": { "type": "prometheus", - "uid": "PBFA97CFB590B2093" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "validator_monitor_validators", @@ -517,7 +523,7 @@ { "datasource": { "type": "prometheus", - "uid": "PBFA97CFB590B2093" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "", @@ -562,7 +568,9 @@ "justifyMode": "center", "orientation": "auto", "reduceOptions": { - "calcs": ["lastNotNull"], + "calcs": [ + "lastNotNull" + ], "fields": "", "values": false }, @@ -576,7 +584,7 @@ { "datasource": { "type": "prometheus", - "uid": "PBFA97CFB590B2093" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "lodestar_version", @@ -662,7 +670,7 @@ { "datasource": { "type": "prometheus", - "uid": "PBFA97CFB590B2093" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "scrape_duration_seconds", @@ -748,7 +756,7 @@ { "datasource": { "type": "prometheus", - "uid": "PBFA97CFB590B2093" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "sum by (job) (\n rate(nodejs_gc_pause_seconds_total[$__rate_interval])\n)", @@ -765,18 +773,146 @@ "refresh": "10s", "schemaVersion": 33, "style": "dark", - "tags": ["lodestar"], + "tags": [ + "lodestar" + ], "templating": { - "list": [] + "list": [ + { + "current": { + "selected": false, + "text": "default", + "value": "default" + }, + "hide": 0, + "includeAll": false, + "label": "datasource", + "multi": false, + "name": "DS_PROMETHEUS", + "options": [], + "query": "prometheus", + "queryValue": "", + "refresh": 1, + "regex": "", + "skipUrlSync": false, + "type": "datasource" + }, + { + "auto": true, + "auto_count": 30, + "auto_min": "10s", + "current": { + "selected": false, + "text": "1h", + "value": "1h" + }, + "hide": 0, + "label": "rate() interval", + "name": "rate_interval", + "options": [ + { + "selected": false, + "text": "auto", + "value": "$__auto_interval_rate_interval" + }, + { + "selected": false, + "text": "1m", + "value": "1m" + }, + { + "selected": false, + "text": "10m", + "value": "10m" + }, + { + "selected": false, + "text": "30m", + "value": "30m" + }, + { + "selected": true, + "text": "1h", + "value": "1h" + }, + { + "selected": false, + "text": "6h", + "value": "6h" + }, + { + "selected": false, + "text": "12h", + "value": "12h" + }, + { + "selected": false, + "text": "1d", + "value": "1d" + }, + { + "selected": false, + "text": "7d", + "value": "7d" + }, + { + "selected": false, + "text": "14d", + "value": "14d" + }, + { + "selected": false, + "text": "30d", + "value": "30d" + } + ], + "query": "1m,10m,30m,1h,6h,12h,1d,7d,14d,30d", + "queryValue": "", + "refresh": 2, + "skipUrlSync": false, + "type": "interval" + }, + { + "datasource": { + "type": "prometheus", + "uid": "prometheus_local" + }, + "filters": [ + { + "condition": "", + "key": "instance", + "operator": "=", + "value": "unstable-lg1k-hzax41" + } + ], + "hide": 0, + "name": "Filters", + "skipUrlSync": false, + "type": "adhoc" + } + ] }, "time": { - "from": "now-12h", + "from": "now-24h", "to": "now" }, - "timepicker": {}, - "timezone": "", + "timepicker": { + "refresh_intervals": [ + "5s", + "10s", + "30s", + "1m", + "5m", + "15m", + "30m", + "1h", + "2h", + "1d" + ] + }, + "timezone": "utc", "title": "Nodes overview", "uid": "lodestar_multinode", "version": 6, - "weekStart": "" + "weekStart": "monday" } diff --git a/dashboards/lodestar_networking.json b/dashboards/lodestar_networking.json index 518c575b5d9d..a5683a3675d5 100644 --- a/dashboards/lodestar_networking.json +++ b/dashboards/lodestar_networking.json @@ -78,7 +78,9 @@ "icon": "external link", "includeVars": true, "keepTime": true, - "tags": ["lodestar"], + "tags": [ + "lodestar" + ], "targetBlank": false, "title": "Lodestar dashboards", "tooltip": "", @@ -560,7 +562,9 @@ "displayMode": "lcd", "orientation": "auto", "reduceOptions": { - "calcs": ["last"], + "calcs": [ + "last" + ], "fields": "", "values": false }, @@ -611,7 +615,9 @@ "displayMode": "lcd", "orientation": "auto", "reduceOptions": { - "calcs": ["last"], + "calcs": [ + "last" + ], "fields": "", "values": false }, @@ -3321,7 +3327,9 @@ "refresh": "10s", "schemaVersion": 35, "style": "dark", - "tags": ["lodestar"], + "tags": [ + "lodestar" + ], "templating": { "list": [ { @@ -3349,8 +3357,8 @@ "auto_min": "10s", "current": { "selected": false, - "text": "6h", - "value": "6h" + "text": "1h", + "value": "1h" }, "hide": 0, "label": "rate() interval", @@ -3377,12 +3385,12 @@ "value": "30m" }, { - "selected": false, + "selected": true, "text": "1h", "value": "1h" }, { - "selected": true, + "selected": false, "text": "6h", "value": "6h" }, @@ -3443,11 +3451,22 @@ "to": "now" }, "timepicker": { - "refresh_intervals": ["5s", "10s", "30s", "1m", "5m", "15m", "30m", "1h", "2h", "1d"] + "refresh_intervals": [ + "5s", + "10s", + "30s", + "1m", + "5m", + "15m", + "30m", + "1h", + "2h", + "1d" + ] }, - "timezone": "", + "timezone": "utc", "title": "Lodestar - networking", "uid": "lodestar_networking", "version": 2, - "weekStart": "" + "weekStart": "monday" } diff --git a/dashboards/lodestar_rest_api.json b/dashboards/lodestar_rest_api.json index c9613d67672a..0fbbe4215bf8 100644 --- a/dashboards/lodestar_rest_api.json +++ b/dashboards/lodestar_rest_api.json @@ -60,7 +60,9 @@ "icon": "external link", "includeVars": true, "keepTime": true, - "tags": ["lodestar"], + "tags": [ + "lodestar" + ], "targetBlank": false, "title": "Lodestar dashboards", "tooltip": "", @@ -615,7 +617,9 @@ "refresh": "10s", "schemaVersion": 35, "style": "dark", - "tags": ["lodestar"], + "tags": [ + "lodestar" + ], "templating": { "list": [ { @@ -643,8 +647,8 @@ "auto_min": "10s", "current": { "selected": false, - "text": "6h", - "value": "6h" + "text": "1h", + "value": "1h" }, "hide": 0, "label": "rate() interval", @@ -671,12 +675,12 @@ "value": "30m" }, { - "selected": false, + "selected": true, "text": "1h", "value": "1h" }, { - "selected": true, + "selected": false, "text": "6h", "value": "6h" }, @@ -733,15 +737,26 @@ ] }, "time": { - "from": "now-12h", + "from": "now-24h", "to": "now" }, "timepicker": { - "refresh_intervals": ["5s", "10s", "30s", "1m", "5m", "15m", "30m", "1h", "2h", "1d"] + "refresh_intervals": [ + "5s", + "10s", + "30s", + "1m", + "5m", + "15m", + "30m", + "1h", + "2h", + "1d" + ] }, - "timezone": "", + "timezone": "utc", "title": "Lodestar - REST API", "uid": "Lodestar_rest_api", "version": 2, - "weekStart": "" + "weekStart": "monday" } diff --git a/dashboards/lodestar_state_cache_regen.json b/dashboards/lodestar_state_cache_regen.json index e2a66ef06934..9f85d6b8458f 100644 --- a/dashboards/lodestar_state_cache_regen.json +++ b/dashboards/lodestar_state_cache_regen.json @@ -61,7 +61,9 @@ "icon": "external link", "includeVars": true, "keepTime": true, - "tags": ["lodestar"], + "tags": [ + "lodestar" + ], "targetBlank": false, "title": "Lodestar dashboards", "tooltip": "", @@ -2513,7 +2515,9 @@ "refresh": "10s", "schemaVersion": 35, "style": "dark", - "tags": ["lodestar"], + "tags": [ + "lodestar" + ], "templating": { "list": [ { @@ -2529,6 +2533,7 @@ "name": "DS_PROMETHEUS", "options": [], "query": "prometheus", + "queryValue": "", "refresh": 1, "regex": "", "skipUrlSync": false, @@ -2540,8 +2545,8 @@ "auto_min": "10s", "current": { "selected": false, - "text": "30m", - "value": "30m" + "text": "1h", + "value": "1h" }, "hide": 0, "label": "rate() interval", @@ -2563,12 +2568,12 @@ "value": "10m" }, { - "selected": true, + "selected": false, "text": "30m", "value": "30m" }, { - "selected": false, + "selected": true, "text": "1h", "value": "1h" }, @@ -2633,10 +2638,23 @@ "from": "now-24h", "to": "now" }, - "timepicker": {}, - "timezone": "", + "timepicker": { + "refresh_intervals": [ + "5s", + "10s", + "30s", + "1m", + "5m", + "15m", + "30m", + "1h", + "2h", + "1d" + ] + }, + "timezone": "utc", "title": "Lodestar - state cache + regen", "uid": "lodestar_state_cache_regen", "version": 3, - "weekStart": "" + "weekStart": "monday" } diff --git a/dashboards/lodestar_summary.json b/dashboards/lodestar_summary.json index 28fcb37529ec..7b8f1dbb5d6c 100644 --- a/dashboards/lodestar_summary.json +++ b/dashboards/lodestar_summary.json @@ -78,7 +78,9 @@ "icon": "external link", "includeVars": true, "keepTime": true, - "tags": ["lodestar"], + "tags": [ + "lodestar" + ], "targetBlank": false, "title": "Lodestar dashboards", "tooltip": "", @@ -363,7 +365,9 @@ "justifyMode": "auto", "orientation": "auto", "reduceOptions": { - "calcs": ["last"], + "calcs": [ + "last" + ], "fields": "", "values": false }, @@ -412,7 +416,9 @@ "justifyMode": "auto", "orientation": "auto", "reduceOptions": { - "calcs": ["lastNotNull"], + "calcs": [ + "lastNotNull" + ], "fields": "", "values": false }, @@ -460,7 +466,9 @@ "justifyMode": "auto", "orientation": "auto", "reduceOptions": { - "calcs": ["lastNotNull"], + "calcs": [ + "lastNotNull" + ], "fields": "", "values": false }, @@ -508,7 +516,9 @@ "justifyMode": "auto", "orientation": "auto", "reduceOptions": { - "calcs": ["lastNotNull"], + "calcs": [ + "lastNotNull" + ], "fields": "", "values": false }, @@ -560,7 +570,9 @@ "justifyMode": "auto", "orientation": "auto", "reduceOptions": { - "calcs": ["lastNotNull"], + "calcs": [ + "lastNotNull" + ], "fields": "", "values": false }, @@ -614,7 +626,9 @@ "justifyMode": "auto", "orientation": "auto", "reduceOptions": { - "calcs": ["lastNotNull"], + "calcs": [ + "lastNotNull" + ], "fields": "", "values": false }, @@ -672,7 +686,9 @@ "justifyMode": "auto", "orientation": "auto", "reduceOptions": { - "calcs": ["lastNotNull"], + "calcs": [ + "lastNotNull" + ], "fields": "", "values": false }, @@ -745,7 +761,9 @@ "justifyMode": "auto", "orientation": "auto", "reduceOptions": { - "calcs": ["lastNotNull"], + "calcs": [ + "lastNotNull" + ], "fields": "", "values": false }, @@ -800,7 +818,9 @@ "justifyMode": "auto", "orientation": "auto", "reduceOptions": { - "calcs": ["lastNotNull"], + "calcs": [ + "lastNotNull" + ], "fields": "", "values": false }, @@ -854,7 +874,9 @@ "justifyMode": "auto", "orientation": "auto", "reduceOptions": { - "calcs": ["lastNotNull"], + "calcs": [ + "lastNotNull" + ], "fields": "", "values": false }, @@ -917,7 +939,9 @@ "justifyMode": "auto", "orientation": "auto", "reduceOptions": { - "calcs": ["lastNotNull"], + "calcs": [ + "lastNotNull" + ], "fields": "", "values": false }, @@ -1404,7 +1428,9 @@ "justifyMode": "center", "orientation": "vertical", "reduceOptions": { - "calcs": ["lastNotNull"], + "calcs": [ + "lastNotNull" + ], "fields": "", "values": false }, @@ -1766,7 +1792,9 @@ "justifyMode": "auto", "orientation": "auto", "reduceOptions": { - "calcs": ["lastNotNull"], + "calcs": [ + "lastNotNull" + ], "fields": "", "values": false }, @@ -1824,7 +1852,9 @@ "justifyMode": "auto", "orientation": "auto", "reduceOptions": { - "calcs": ["lastNotNull"], + "calcs": [ + "lastNotNull" + ], "fields": "", "values": false }, @@ -1882,7 +1912,9 @@ "justifyMode": "auto", "orientation": "auto", "reduceOptions": { - "calcs": ["lastNotNull"], + "calcs": [ + "lastNotNull" + ], "fields": "", "values": false }, @@ -1940,7 +1972,9 @@ "justifyMode": "auto", "orientation": "auto", "reduceOptions": { - "calcs": ["lastNotNull"], + "calcs": [ + "lastNotNull" + ], "fields": "", "values": false }, @@ -1998,7 +2032,9 @@ "justifyMode": "auto", "orientation": "auto", "reduceOptions": { - "calcs": ["lastNotNull"], + "calcs": [ + "lastNotNull" + ], "fields": "", "values": false }, @@ -2069,7 +2105,9 @@ "justifyMode": "auto", "orientation": "auto", "reduceOptions": { - "calcs": ["lastNotNull"], + "calcs": [ + "lastNotNull" + ], "fields": "", "values": false }, @@ -2687,7 +2725,9 @@ "refresh": "10s", "schemaVersion": 35, "style": "dark", - "tags": ["lodestar"], + "tags": [ + "lodestar" + ], "templating": { "list": [ { @@ -2715,8 +2755,8 @@ "auto_min": "10s", "current": { "selected": false, - "text": "6h", - "value": "6h" + "text": "1h", + "value": "1h" }, "hide": 0, "label": "rate() interval", @@ -2743,12 +2783,12 @@ "value": "30m" }, { - "selected": false, + "selected": true, "text": "1h", "value": "1h" }, { - "selected": true, + "selected": false, "text": "6h", "value": "6h" }, @@ -2809,11 +2849,22 @@ "to": "now" }, "timepicker": { - "refresh_intervals": ["5s", "10s", "30s", "1m", "5m", "15m", "30m", "1h", "2h", "1d"] + "refresh_intervals": [ + "5s", + "10s", + "30s", + "1m", + "5m", + "15m", + "30m", + "1h", + "2h", + "1d" + ] }, - "timezone": "", + "timezone": "utc", "title": "Lodestar", "uid": "lodestar", "version": 7, - "weekStart": "" + "weekStart": "monday" } diff --git a/dashboards/lodestar_sync.json b/dashboards/lodestar_sync.json index 1ac8d9a9ef22..e47c4ec220ad 100644 --- a/dashboards/lodestar_sync.json +++ b/dashboards/lodestar_sync.json @@ -60,7 +60,9 @@ "icon": "external link", "includeVars": true, "keepTime": true, - "tags": ["lodestar"], + "tags": [ + "lodestar" + ], "targetBlank": false, "title": "Lodestar dashboards", "tooltip": "", @@ -1343,7 +1345,10 @@ { "id": "custom.lineStyle", "value": { - "dash": [10, 10], + "dash": [ + 10, + 10 + ], "fill": "dash" } } @@ -1557,7 +1562,9 @@ "refresh": "10s", "schemaVersion": 35, "style": "dark", - "tags": ["lodestar"], + "tags": [ + "lodestar" + ], "templating": { "list": [ { @@ -1585,8 +1592,8 @@ "auto_min": "10s", "current": { "selected": false, - "text": "6h", - "value": "6h" + "text": "1h", + "value": "1h" }, "hide": 0, "label": "rate() interval", @@ -1613,12 +1620,12 @@ "value": "30m" }, { - "selected": false, + "selected": true, "text": "1h", "value": "1h" }, { - "selected": true, + "selected": false, "text": "6h", "value": "6h" }, @@ -1679,11 +1686,22 @@ "to": "now" }, "timepicker": { - "refresh_intervals": ["5s", "10s", "30s", "1m", "5m", "15m", "30m", "1h", "2h", "1d"] + "refresh_intervals": [ + "5s", + "10s", + "30s", + "1m", + "5m", + "15m", + "30m", + "1h", + "2h", + "1d" + ] }, - "timezone": "", + "timezone": "utc", "title": "Lodestar - sync", "uid": "lodestar_sync", "version": 2, - "weekStart": "" + "weekStart": "monday" } diff --git a/dashboards/lodestar_validator_client.json b/dashboards/lodestar_validator_client.json index 373f240f15e0..db559a295acf 100644 --- a/dashboards/lodestar_validator_client.json +++ b/dashboards/lodestar_validator_client.json @@ -78,7 +78,9 @@ "icon": "external link", "includeVars": true, "keepTime": true, - "tags": ["lodestar"], + "tags": [ + "lodestar" + ], "targetBlank": false, "title": "Lodestar dashboards", "tooltip": "", @@ -246,7 +248,9 @@ "justifyMode": "auto", "orientation": "auto", "reduceOptions": { - "calcs": ["lastNotNull"], + "calcs": [ + "lastNotNull" + ], "fields": "", "values": false }, @@ -313,7 +317,9 @@ "justifyMode": "auto", "orientation": "auto", "reduceOptions": { - "calcs": ["lastNotNull"], + "calcs": [ + "lastNotNull" + ], "fields": "", "values": false }, @@ -378,7 +384,9 @@ "justifyMode": "auto", "orientation": "auto", "reduceOptions": { - "calcs": ["lastNotNull"], + "calcs": [ + "lastNotNull" + ], "fields": "", "values": false }, @@ -444,7 +452,9 @@ "justifyMode": "auto", "orientation": "auto", "reduceOptions": { - "calcs": ["lastNotNull"], + "calcs": [ + "lastNotNull" + ], "fields": "", "values": false }, @@ -508,7 +518,9 @@ "justifyMode": "auto", "orientation": "auto", "reduceOptions": { - "calcs": ["lastNotNull"], + "calcs": [ + "lastNotNull" + ], "fields": "", "values": false }, @@ -572,7 +584,9 @@ "justifyMode": "auto", "orientation": "auto", "reduceOptions": { - "calcs": ["lastNotNull"], + "calcs": [ + "lastNotNull" + ], "fields": "", "values": false }, @@ -1913,7 +1927,9 @@ "refresh": "10s", "schemaVersion": 35, "style": "dark", - "tags": ["lodestar"], + "tags": [ + "lodestar" + ], "templating": { "list": [ { @@ -1941,8 +1957,8 @@ "auto_min": "10s", "current": { "selected": false, - "text": "30m", - "value": "30m" + "text": "1h", + "value": "1h" }, "hide": 0, "label": "rate() interval", @@ -1964,12 +1980,12 @@ "value": "10m" }, { - "selected": true, + "selected": false, "text": "30m", "value": "30m" }, { - "selected": false, + "selected": true, "text": "1h", "value": "1h" }, @@ -2034,10 +2050,23 @@ "from": "now-24h", "to": "now" }, - "timepicker": {}, - "timezone": "", + "timepicker": { + "refresh_intervals": [ + "5s", + "10s", + "30s", + "1m", + "5m", + "15m", + "30m", + "1h", + "2h", + "1d" + ] + }, + "timezone": "utc", "title": "Lodestar validator client", "uid": "lodestar_validator_client", "version": 3, - "weekStart": "" + "weekStart": "monday" } diff --git a/dashboards/lodestar_validator_monitor.json b/dashboards/lodestar_validator_monitor.json index e01a3a2558fb..ab4e702133f5 100644 --- a/dashboards/lodestar_validator_monitor.json +++ b/dashboards/lodestar_validator_monitor.json @@ -78,7 +78,9 @@ "icon": "external link", "includeVars": true, "keepTime": true, - "tags": ["lodestar"], + "tags": [ + "lodestar" + ], "targetBlank": false, "title": "Lodestar dashboards", "tooltip": "", @@ -124,7 +126,9 @@ "justifyMode": "auto", "orientation": "auto", "reduceOptions": { - "calcs": ["lastNotNull"], + "calcs": [ + "lastNotNull" + ], "fields": "", "values": false }, @@ -186,7 +190,9 @@ "options": { "footer": { "fields": "", - "reducer": ["sum"], + "reducer": [ + "sum" + ], "show": false }, "frameIndex": 0, @@ -1408,7 +1414,9 @@ "refresh": "10s", "schemaVersion": 35, "style": "dark", - "tags": ["lodestar"], + "tags": [ + "lodestar" + ], "templating": { "list": [ { @@ -1424,6 +1432,7 @@ "name": "DS_PROMETHEUS", "options": [], "query": "prometheus", + "queryValue": "", "refresh": 1, "regex": "", "skipUrlSync": false, @@ -1434,7 +1443,7 @@ "auto_count": 30, "auto_min": "10s", "current": { - "selected": true, + "selected": false, "text": "1h", "value": "1h" }, @@ -1528,10 +1537,23 @@ "from": "now-24h", "to": "now" }, - "timepicker": {}, - "timezone": "", + "timepicker": { + "refresh_intervals": [ + "5s", + "10s", + "30s", + "1m", + "5m", + "15m", + "30m", + "1h", + "2h", + "1d" + ] + }, + "timezone": "utc", "title": "Lodestar - validator monitor", "uid": "lodestar_validator_monitor", "version": 2, - "weekStart": "" + "weekStart": "monday" } diff --git a/dashboards/lodestar_vm_host.json b/dashboards/lodestar_vm_host.json index d5e0f84b42b9..cf67c407ffee 100644 --- a/dashboards/lodestar_vm_host.json +++ b/dashboards/lodestar_vm_host.json @@ -354,7 +354,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "nodejs_heap_size_total_bytes{job=\"beacon\"}", @@ -366,7 +366,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "nodejs_heap_size_used_bytes{job=\"beacon\"}", @@ -378,7 +378,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "nodejs_external_memory_bytes{job=\"beacon\"}", @@ -390,7 +390,7 @@ { "datasource": { "type": "prometheus", - "uid": "prometheus_local" + "uid": "${DS_PROMETHEUS}" }, "exemplar": false, "expr": "process_resident_memory_bytes{job=\"beacon\"}", @@ -3556,8 +3556,8 @@ "auto_min": "10s", "current": { "selected": false, - "text": "30m", - "value": "30m" + "text": "1h", + "value": "1h" }, "hide": 0, "label": "rate() interval", @@ -3579,12 +3579,12 @@ "value": "10m" }, { - "selected": true, + "selected": false, "text": "30m", "value": "30m" }, { - "selected": false, + "selected": true, "text": "1h", "value": "1h" }, @@ -3663,9 +3663,9 @@ "1d" ] }, - "timezone": "", + "timezone": "utc", "title": "Lodestar - VM + host", "uid": "lodestar_vm_host", "version": 6, - "weekStart": "" -} \ No newline at end of file + "weekStart": "monday" +} diff --git a/scripts/lint-grafana-dashboards.mjs b/scripts/lint-grafana-dashboards.mjs new file mode 100755 index 000000000000..879204bd16d5 --- /dev/null +++ b/scripts/lint-grafana-dashboards.mjs @@ -0,0 +1,228 @@ +#!/usr/bin/env node + +import fs from "node:fs"; +import path from "node:path"; + +// USAGE: +// node lint-grafana-dashboards.mjs ./dashboards + +/* eslint-disable +@typescript-eslint/no-unsafe-assignment, +@typescript-eslint/explicit-function-return-type, +@typescript-eslint/naming-convention, +no-console +*/ + +const dirpath = process.argv[2]; +if (!dirpath) throw Error("Must provide dirpath argument"); + +const filenames = fs.readdirSync(dirpath); +if (filenames.length === 0) throw Error(`Empty dir ${dirpath}`); + +/** + * @typedef {Object} Dashboard + * @property {Panel[]} [panels] + * @property {string[]} [tags] + * @property {Link[]} [links] + * @property {Time} [time] + * @property {Timepicker} [timepicker] + * @property {string} [timezone] + * @property {string} [weekStart] + * @property {string} [refresh] + * @property {Templating} [templating] + * + * @typedef {Object} Panel + * @property {Target[]} [targets] + * + * @typedef {Object} Target + * @property {Datasource} [datasource] + * @property {boolean} [exemplar] + * @property {string} [expr] + * + * @typedef {Object} Datasource + * @property {string} type + * @property {string} uid + * + * @typedef {Object} Link + * @property {string} title + * + * @typedef {Object} Time + * @property {string} from + * @property {string} to + * + * @typedef {Object} Timepicker + * @property {string[]} refresh_intervals + * + * @typedef {Object} Templating + * @property {TemplatingListItem[]} [list] + * + * @typedef {Object} TemplatingListItem + * @property {string} name + */ + +const variableNameDatasource = "DS_PROMETHEUS"; +const variableNameRateInterval = "rate_interval"; +const variableNameFilters = "Filters"; + +for (const filename of filenames) { + if (!filename.endsWith(".json")) { + continue; + } + + const jsonStr = fs.readFileSync(path.join(dirpath, filename), "utf8"); + /** @type {Dashboard} */ + const json = JSON.parse(jsonStr); + + if (json.panels) { + for (const panel of json.panels) { + if (panel.targets) { + for (const target of panel.targets) { + // All panels must point to the datasource variable + if (target.datasource) { + target.datasource.type = "prometheus"; + target.datasource.uid = "${DS_PROMETHEUS}"; + } + + // Disable exemplar + if (target.exemplar !== undefined) { + target.exemplar = false; + } + + // Force usage of interval variable + if (target.expr) { + target.expr.replace(/\$__rate_interval/g, `$${variableNameRateInterval}`); + } + } + } + } + } + + const LODESTAR_TAG = "lodestar"; + + // Force add lodestar tag for easy navigation + if (!json.tags) json.tags = []; + if (!json.tags.includes(LODESTAR_TAG)) json.tags.push(LODESTAR_TAG); + + // Add links section + const LINK_TITLE = "Lodestar dashboards"; + + if (!json.links) json.links = []; + if (!json.links.some((link) => link.title === LINK_TITLE)) { + json.links.push({ + asDropdown: true, + icon: "external link", + includeVars: true, + keepTime: true, + tags: [LODESTAR_TAG], + targetBlank: false, + title: LINK_TITLE, + tooltip: "", + type: "dashboards", + url: "", + }); + } + + // Force time on a constant time window + json.refresh = "10s"; + json.time = { + from: "now-24h", + to: "now", + }; + + // Force timezone and time settings + json.timezone = "utc"; + json.weekStart = "monday"; + if (!json.timepicker) json.timepicker = {}; + json.timepicker.refresh_intervals = ["5s", "10s", "30s", "1m", "5m", "15m", "30m", "1h", "2h", "1d"]; + + // Add common variables + if (!json.templating) json.templating = {}; + if (!json.templating.list) json.templating.list = []; + + assertTemplatingListItemContent(json, variableNameDatasource, { + current: {selected: false, text: "default", value: "default"}, + hide: 0, + includeAll: false, + label: "datasource", + multi: false, + name: variableNameDatasource, + options: [], + query: "prometheus", + queryValue: "", + refresh: 1, + regex: "", + skipUrlSync: false, + type: "datasource", + }); + + assertTemplatingListItemContent(json, variableNameRateInterval, { + auto: true, + auto_count: 30, + auto_min: "10s", + current: {selected: false, text: "1h", value: "1h"}, + hide: 0, + label: "rate() interval", + name: variableNameRateInterval, + options: [ + {selected: false, text: "auto", value: "$__auto_interval_rate_interval"}, + {selected: false, text: "1m", value: "1m"}, + {selected: false, text: "10m", value: "10m"}, + {selected: false, text: "30m", value: "30m"}, + {selected: true, text: "1h", value: "1h"}, + {selected: false, text: "6h", value: "6h"}, + {selected: false, text: "12h", value: "12h"}, + {selected: false, text: "1d", value: "1d"}, + {selected: false, text: "7d", value: "7d"}, + {selected: false, text: "14d", value: "14d"}, + {selected: false, text: "30d", value: "30d"}, + ], + query: "1m,10m,30m,1h,6h,12h,1d,7d,14d,30d", + queryValue: "", + refresh: 2, + skipUrlSync: false, + type: "interval", + }); + + assertTemplatingListItemContent(json, variableNameFilters, { + datasource: { + type: "prometheus", + uid: "prometheus_local", + }, + filters: [ + { + condition: "", + key: "instance", + operator: "=", + value: "unstable-lg1k-hzax41", + }, + ], + hide: 0, + name: "Filters", + skipUrlSync: false, + type: "adhoc", + }); + + // Add new line + const jsonStrOut = JSON.stringify(json, null, 2) + "\n"; + fs.writeFileSync(path.join(dirpath, filename), jsonStrOut); +} + +/** + * @param {Dashboard} json + * @param {string} varName + * @param {TemplatingListItem} item + */ +function assertTemplatingListItemContent(json, varName, item) { + if (!json.templating) json.templating = {}; + if (!json.templating.list) json.templating.list = []; + + const index = json.templating.list.findIndex((item) => item.name === varName); + + if (index < 0) { + // No match, push new item + json.templating.list.push(item); + } else { + // Match replace content + json.templating.list[index] = item; + } +} diff --git a/scripts/validate-grafana-dashboard.mjs b/scripts/validate-grafana-dashboard.mjs deleted file mode 100755 index 0a9fdfeba4de..000000000000 --- a/scripts/validate-grafana-dashboard.mjs +++ /dev/null @@ -1,86 +0,0 @@ -#!/usr/bin/env node - -import fs from "node:fs"; -import path from "node:path"; - -// USAGE: -// node validate-grafana-dashboard.mjs ./dashboards - -/* eslint-disable -@typescript-eslint/no-unsafe-assignment, -@typescript-eslint/explicit-function-return-type, -no-console -*/ - -const dirpath = process.argv[2]; -if (!dirpath) throw Error("Must provide dirpath argument"); - -const filenames = fs.readdirSync(dirpath); -if (filenames.length === 0) throw Error(`Empty dir ${dirpath}`); - -/** @type {string[]} */ -const errors = []; - -for (const filename of filenames) { - if (!filename.endsWith(".json")) { - continue; - } - - const jsonStr = fs.readFileSync(path.join(dirpath, filename), "utf8"); - const json = JSON.parse(jsonStr); - - for (const errorStr of [assertNoExemplar(json), assertLodestarTag(json), assertLinks(json)]) { - if (errorStr) { - errors.push(`${filename}: ${errorStr}`); - } - } -} - -if (errors.length > 0) { - throw Error(`Some dashboards are invalid:\n${errors.join("\n")}`); -} - -/** - * The complete Triforce, or one or more components of the Triforce. - * @typedef {Object} Dashboard - * @property {string[]} tags - * @property {Object[]} links - */ - -function assertNoExemplar(json) { - // get everything in the same line - const jsonStrSameLine = JSON.stringify(json); - - // match something like exemplar : true - const matches = jsonStrSameLine.match(/(exemplar)(\s)*(["])?(\s)*:(\s)*(["])?(\s)*true/gi); - if (matches && matches.length > 0) { - return "ExemplarQueryNotSupported, replace '\"exemplar\": true' with '\"exemplar\": false'"; - } -} - -/** @param {Dashboard} json */ -function assertLodestarTag(json) { - if (!json.tags.includes("lodestar")) { - return "Dashboard .tags must include 'lodestar'"; - } -} - -/** @param {Dashboard} json */ -function assertLinks(json) { - if (!json.links.some((link) => link.type === "dashboards")) { - return `Dashboard .links must include a link object with - { - "asDropdown": true, - "icon": "external link", - "includeVars": true, - "keepTime": true, - "tags": ["lodestar"], - "targetBlank": false, - "title": "Lodestar dashboards", - "tooltip": "", - "type": "dashboards", - "url": "" - } - `; - } -} diff --git a/scripts/validate-grafana-dashboards.sh b/scripts/validate-grafana-dashboards.sh new file mode 100755 index 000000000000..e2b2436a4a7c --- /dev/null +++ b/scripts/validate-grafana-dashboards.sh @@ -0,0 +1,12 @@ +#!/bin/bash + +# This script will mutate the dashboards if anything needs linting +node scripts/lint-grafana-dashboards.mjs ./dashboards + +if [[ $(git diff ./dashboards --stat) != '' ]]; then + git --no-pager diff + echo 'dashboards need fixing' + exit 1 +else + echo 'dashboards clean' +fi \ No newline at end of file