20 Feb 2023 02:00 AM - last edited on 20 Feb 2023 08:31 AM by MaciejNeumann
I am looking to splitBy a tag for a metric expression to generate one SLO definition that covers all entities.
The use-case is instead of having hundreds of metrics/SLOs defined per tag value (i.e. using a filter), to instead split by the tag.
On the metricsSelector, I can only seem to splitBy an available dimension and tags is not one of these. Is this use-case possible, or are multiple entitySelectors with filters for each tagging value necessary?
Did anyone have examples of how they solved this before?
Management zone filters the SLO dashboard tiles by the selected data, so it seems this calculation is possible. But it would have to be beyond dashboards, such as SLO alerts, etc.
Solved! Go to Solution.
20 Feb 2023 04:43 AM
Hey Andrew,
From what I've seen this will be possible once metrics on Grail rolls around allowing for DQL queries against metrics. I haven't found a workaround in the current metric selector.
Looking at this blog post, Expanded Grail data lakehouse and new Dynatrace user experience unlock boundless analytics | Dynatra..., I reckon to do something like splitting by a parameter the DQL would look something like:
fetch dt.entity.host
| lookup [fetch metrics
| filter metric.key == "dt.host.cpu.system"
| summarize avg = avg(value), by:dt.entity.host], sourceField:entityId, lookupField:dt.entity.host
| summarize avg(lookup.avg), by:{cpuCores}
The above example would splitBy core count.
22 Feb 2023 12:03 AM
Thanks Fin