Skip to content

Commit b0427e6

Browse files
committed
dashboard: add panel for config application status
1 parent 67ccab6 commit b0427e6

File tree

8 files changed

+780
-527
lines changed

8 files changed

+780
-527
lines changed

CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,12 @@ All notable changes to this project will be documented in this file.
44
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
55
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
66

7+
## [Unreleased]
8+
9+
### Added
10+
- Panel with Сartridge config application status
11+
12+
713
## [3.2.1] - 2024-12-06
814
Grafana revisions:
915
- Tarantool 3:

dashboard/panels/cluster.libsonnet

Lines changed: 28 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -344,6 +344,33 @@ local prometheus = grafana.prometheus;
344344
else if cfg.type == variable.datasource_type.influxdb then
345345
error 'InfluxDB target is not supported yet',
346346

347+
config_applied(
348+
cfg,
349+
title='Config application status',
350+
description=|||
351+
Indicates whether the instance has locally applied a new
352+
clusterwide configuration.
353+
354+
Panel minimal requirements: cartridge 2.16.1, metrics 1.4.0.
355+
|||,
356+
):: timeseries.new(
357+
title=title,
358+
description=description,
359+
datasource=cfg.datasource,
360+
panel_height=6,
361+
panel_width=8,
362+
max=1,
363+
min=0,
364+
).addValueMapping(
365+
0, 'yellow', 'not applied'
366+
).addValueMapping(
367+
1, 'green', 'applied'
368+
).addRangeMapping(
369+
0.001, 0.999, '-'
370+
).addTarget(
371+
common.target(cfg, 'tnt_cartridge_config_applied')
372+
),
373+
347374
memory_reserved_stat(
348375
cfg,
349376
title='',
@@ -452,7 +479,7 @@ local prometheus = grafana.prometheus;
452479
legend_avg=false,
453480
legend_max=false,
454481
panel_height=6,
455-
panel_width=12,
482+
panel_width=8,
456483
).addTarget(
457484
common.target(
458485
cfg,

dashboard/section.libsonnet

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,7 @@ local vinyl = import 'dashboard/panels/vinyl.libsonnet';
6767
cluster.http_rps_stat(cfg) { gridPos: { w: 4, h: 5, x: 12, y: 4 } },
6868
cluster.net_rps_stat(cfg) { gridPos: { w: 4, h: 5, x: 16, y: 4 } },
6969
cluster.space_ops_stat(cfg) { gridPos: { w: 4, h: 5, x: 20, y: 4 } },
70+
cluster.config_applied(cfg),
7071
cluster.cartridge_warning_issues(cfg),
7172
cluster.cartridge_critical_issues(cfg),
7273
cluster.failovers_per_second(cfg),

supported_metrics.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -121,6 +121,7 @@ Based on [tarantool/metrics 1.2.0](https://github.com/tarantool/metrics/releases
121121
- [x] **tnt_cartridge_issues**: see *Cluster overview/Cartridge warning issues*, *Cluster overview/Cartridge critical issues* panels ([#55](https://github.com/tarantool/grafana-dashboard/pull/55))
122122
- **tnt_cartridge_cluster_issues**: unsupported (decided not to support: superseded by **tnt_cartridge_issues**)
123123
- [x] **tnt_cartridge_failover_trigger_total**: see *Cluster overview/Failovers triggered* panel ([#178](https://github.com/tarantool/grafana-dashboard/issues/178))
124+
- [x] **tnt_cartridge_config_applied**: see *Cluster overview/Config application status* panel
124125
- [x] **tnt_synchro_queue_owner**: see *Replication overview/Synchronous queue owner* panel ([#178](https://github.com/tarantool/grafana-dashboard/issues/178))
125126
- [x] **tnt_synchro_queue_term**: see *Replication overview/Synchronous queue term* panel ([#178](https://github.com/tarantool/grafana-dashboard/issues/178))
126127
- [x] **tnt_synchro_queue_len**: see *Replication overview/Synchronous queue transactions* panel ([#178](https://github.com/tarantool/grafana-dashboard/issues/178))

tests/InfluxDB/dashboard_cartridge_compiled.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@
6464
"fill": 0,
6565
"gridPos": {
6666
"h": 6,
67-
"w": 12,
67+
"w": 8,
6868
"x": 0,
6969
"y": 1
7070
},
@@ -204,8 +204,8 @@
204204
"fill": 0,
205205
"gridPos": {
206206
"h": 6,
207-
"w": 12,
208-
"x": 12,
207+
"w": 8,
208+
"x": 8,
209209
"y": 1
210210
},
211211
"id": 4,

tests/InfluxDB/dashboard_tdg_compiled.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@
6464
"fill": 0,
6565
"gridPos": {
6666
"h": 6,
67-
"w": 12,
67+
"w": 8,
6868
"x": 0,
6969
"y": 1
7070
},
@@ -204,8 +204,8 @@
204204
"fill": 0,
205205
"gridPos": {
206206
"h": 6,
207-
"w": 12,
208-
"x": 12,
207+
"w": 8,
208+
"x": 8,
209209
"y": 1
210210
},
211211
"id": 4,

0 commit comments

Comments
 (0)