Skip to content

Commit

Permalink
dashboard: fill with none for InfluxDB
Browse files Browse the repository at this point in the history
On lower timescales data with "fill(null)" seems like a scattered set
of dots. Data with "fill(none)" seems fine like a line string. I don't
remember these issues on older Grafana versions, so it is possible
that something had changed with visualization even for deprecated graph
panels.
  • Loading branch information
DifferentialOrange committed Jul 9, 2024
1 parent 62456a7 commit ffd66fd
Show file tree
Hide file tree
Showing 11 changed files with 983 additions and 982 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
It affects all custom-built dashboards which had used `replication` (#224)
- Remove deprecated `build-static-*` targets from `make` (#224)
- Make default template use Tarantool 3 sections (#224)
- Use `fill(none)` in InfluxQL requests (PR #229)

### Fixed
- Removed extra quotation mark for TDG jobs_average_panel query (#220)
Expand Down
2 changes: 1 addition & 1 deletion dashboard/panels/common.libsonnet
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ local influxdb_query_filters(filters) = std.join(' AND ', std.map(
measurement=cfg.measurement,
group_tags=group_tags,
alias=legend[cfg.type],
fill='null',
fill='none',
).where('metric_name', '=', std.format('%s%s', [cfg.metrics_prefix, metric_name]))
).selectField('value').addConverter(converter);
if rate then target.addConverter('non_negative_derivative', ['1s']) else target,
Expand Down
2 changes: 1 addition & 1 deletion dashboard/panels/tdg/graphql.libsonnet
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ local prometheus = grafana.prometheus;
WHERE ("metric_name" = '%(metrics_prefix)s%(metric_name_count)s' %(filters)s)
AND $timeFilter)
GROUP BY time($__interval), "label_pairs_alias", "label_pairs_operation_name",
"label_pairs_schema", "label_pairs_entity" fill(null)
"label_pairs_schema", "label_pairs_entity" fill(none)
|||, {
metrics_prefix: cfg.metrics_prefix,
metric_name_sum: std.join('_', [metric_name, 'sum']),
Expand Down
4 changes: 2 additions & 2 deletions dashboard/panels/tdg/tasks.libsonnet
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ local prometheus = grafana.prometheus;
(SELECT "value" as "%(metrics_prefix)s%(metric_name_count)s" FROM %(policy_prefix)s"%(measurement)s"
WHERE ("metric_name" = '%(metrics_prefix)s%(metric_name_count)s' %(filters)s)
AND $timeFilter)
GROUP BY time($__interval), "label_pairs_alias", "label_pairs_name" fill(null)
GROUP BY time($__interval), "label_pairs_alias", "label_pairs_name" fill(none)
|||, {
metrics_prefix: cfg.metrics_prefix,
metric_name_sum: std.join('_', [metric_name, 'sum']),
Expand Down Expand Up @@ -221,7 +221,7 @@ local prometheus = grafana.prometheus;
WHERE ("metric_name" = '%(metrics_prefix)s%(metric_name_count)s' %(filters)s)
AND $timeFilter)
GROUP BY time($__interval), "label_pairs_alias", "label_pairs_name",
"label_pairs_kind" fill(null)
"label_pairs_kind" fill(none)
|||, {
metrics_prefix: cfg.metrics_prefix,
metric_name_sum: std.join('_', [metric_name, 'sum']),
Expand Down
2 changes: 1 addition & 1 deletion dashboard/panels/tdg/tuples.libsonnet
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ local prometheus = grafana.prometheus;
WHERE ("metric_name" = '%(metrics_prefix)s%(metric_name_sum)s' %(filters)s) AND $timeFilter),
(SELECT "value" as "%(metrics_prefix)s%(metric_name_count)s" FROM %(policy_prefix)s"%(measurement)s"
WHERE ("metric_name" = '%(metrics_prefix)s%(metric_name_count)s' %(filters)s) AND $timeFilter)
GROUP BY time($__interval), "label_pairs_alias", "label_pairs_type_name" fill(null)
GROUP BY time($__interval), "label_pairs_alias", "label_pairs_type_name" fill(none)
|||, {
metrics_prefix: cfg.metrics_prefix,
metric_name_sum: std.join('_', [metric_name, 'sum']),
Expand Down
Loading

0 comments on commit ffd66fd

Please sign in to comment.