cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Single value tile with sparkline and trend as in classic metric explorer in new Dashboards

rastislav_danis
DynaMight Pro
DynaMight Pro

I have tried simple single value via timeseries cpu=avg(dt.host.cpu.usage) data.

I had learned that output of timeseries is array, so single value is not possible (blank widget without any info, but it shows trend at least, when i select timeframe/interval as input data).

Another try was timeseries cpu=avg(dt.host.cpu.usage)|fields cpuavg=arrayAvg(cpu).

This produces nice single value but doesn't allow to visualize sparkline, nor trends (as it's only single number obviously).

I had tried to push array as well via timeseries cpu=avg(dt.host.cpu.usage)|fields cpu,cpuavg=arrayAvg(cpu), but sparkline does not allow to use cpu array as data source (shows None as record field only option).

I know it's only early access, but any hints how to achieve such a simple task ? (single value with sparkline and trend as in classic metric explorer)

Alanata a.s.
1 REPLY 1

Alejandro
Dynatrace Enthusiast
Dynatrace Enthusiast

I think your approach is almost perfect but, when you use fields you limit the amount of fields returned in the query. You can directly add the extra calculation with fieldsAdd.

I believe the following query should fit your needs and let you visualize everything in a single value tile:

timeseries cpu=avg(dt.host.cpu.usage)
| fieldsAdd cpuAvg=arrayAvg(cpu)

Featured Posts