29 May 2024 07:32 PM - last edited on 07 Jun 2024 01:29 PM by Michal_Gebacki
I'm looking to add data to a dashboard such as logical CPU Core count totals from data collected by the OneAgent but cannot find a way to add this information, I know there are APIs that can gather this information, but how can I add them to a dashboard?
(Managed Environment)
Solved! Go to Solution.
29 May 2024 08:48 PM
In general, this is not easily possible. Apart from the specific tiles, basically you are left with data explorer or markdown. Data Explorer can only display metrics. Number of CPU cores is unfortunately not a metric, but an attribute.
Probably the best you can achieve with classic dashboard (only option in Managed) is to have a list of hosts which have fixed CPU cores value (or any other attribute) by using entitySelectors, for example:
builtin:host.cpu.usage
:filter(in("dt.entity.host",entitySelector("type(host),cpuCores(4)")))
:splitBy("dt.entity.host")
You can also use metric expression, so you can have a static value of 1:
builtin:host.cpu.usage
:filter(in("dt.entity.host",entitySelector("type(host),cpuCores(4)")))
:splitBy("dt.entity.host")
/
builtin:host.cpu.usage
:filter(in("dt.entity.host",entitySelector("type(host),cpuCores(4)")))
:splitBy("dt.entity.host")
Which displays quite nicely.
If you dashboard is static - you can also consider having a markdown time which will be updated by automation of your choice and using the Dynatrace Dashboard API.