I am now deciding whether to use metrics API or DQL to query metrics. But now, I am facing a problem that I can’t find some metrics using DQL. (e.g. builtin:host.cpu.load15m)
Is that all metrics that can be queried by metrics selector can also be use DQL to query?
Hi Stephen - DQL is only used for querying logs and events with Grail: DQL Documentation.
For the metric selector, metric queries are handled differently, and do not use DQL. I’d recommend checking out the Data Explorer Advanced Mode to get a better idea of how metric queries are handled.
As of the late May / early June 2023 Dynatrace rollout, this is now possible via DQL. Please view MaciejNeumann reply for a link to the metrics covered with Grail.
With the rollout of the latest Dynatrace, the DQL can also query metrics. Here you can find the documentation article with the list of all metrics supported by Grail:
So is there a way to use DQL in API queries? So far in all the docs, I don’t see any mention of using DQL commands and queries in the API, only in the new web console. Is this coming down the pipe?
I ask because I find the Dynatrace API extremely complex and very limiting compared to many other API’s I’ve used for similar tools. However, if we could use DQL queries in our API calls that would pretty much solve all of the issues I have with the Dynatrace API and make it extremely powerful.