I am using the Infinity Datasource to connect to Dynatrace (API). The Dynatrace plugin doesn’t give me all i need. But when getting time series data the values and timestamps are two separate arrays. I am struggling how to merge them together. I am usin UQL and if i use mv_expand on both then it matches each value from each array to the other. I put a small sample below. any help is appreciated.
{
“totalCount”: 10,
“nextPageKey”: null,
“resolution”: “1m”,
“result”: [
{
“metricId”: “builtin:host.cpu.usage:names:filter(in("dt.entity.host",entitySelector("type(~"HOST~"),tag(~"appcode:aaa~")"))):splitBy("dt.entity.host.name"):sort(dimension("dt.entity.host.name",ascending)):avg”,
“dataPointCountRatio”: 6.0E-5,
“dimensionCountRatio”: 1.0E-4,
“data”: [
{
"dimensions": [
"hostxxx@yyy.com"
],
"dimensionMap": {
"dt.entity.host.name": "hostxxx@yyy.com"
},
"timestamps": [
1701090120000,
1701090180000,
1701090240000,
1701090300000,
1701090360000
],
"values": [
90.19648106892903,
90.06653912862141,
91.63350741068523,
91.0315596262614,
92.09268697102864
]
}
]
}
]
}