Dashboarding
Dynatrace dashboards, notebooks, and data explorer explained.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

DataPower Extensions metric : how to turn last response time to a response time graph

leeb
Newcomer

Hi

The DataPower extension provides for each webservice a "Last Response Time" metric. Rather than a long graph with the same response time line in the case there is no response in a timeframe, I wanted to turn this into a positive response time graph instead.

I managed to get as far as this in DQL, where I am getting a graph effectively of the delta in response time between the last response and the next one.. Is it possible to graph based off last response time, but calculate based off of response time delta?

 Attached is a screenshot of the "lastResponseTime" metric and the delta graph the below DQL provides

I would like to actually graph the response time if it is changed but zero if it is unchanged (ie no request in that time interval)

DQL code for tile below :

timeseries lastResponseTime = max(IBM.DataPower.WebService.lastResponseTime), by: { `dt.entity.datapower:webservice`, `dt.entity.datapower:instance` }
| fieldsAdd array(lastResponseTime),entityName(`dt.entity.datapower:webservice`), entityName(`dt.entity.datapower:instance`), arrayDelta(lastResponseTime)
| sort (lastResponseTime) desc
| limit 20

When I look at the visualization tab i chose the lastResponseTime I get continuous lines for unchanged data, if I chose the arrayDelta one i am getting effectively the delta between this response time and the last one which is not the same as the actual response time.

leeb_0-1765281771362.png

Wasnt sure if this was a DQL question or a dashboard question pertaining to visualization options so posted here.

1 REPLY 1

Anderson-Luna
Dynatrace Enthusiast
Dynatrace Enthusiast

Hi leeb,
to get a “positive-only” graph (show the actual last response time when there were requests, otherwise 0), use the request counter from the DataPower extension as a mask and apply element‑wise logic on the arrays returned by timeseries, I came up with the following dql:

timeseries {
  lastResponseTime = max(IBM.DataPower.WebService.lastResponseTime),
  requests         = sum(IBM.DataPower.WebService.totalRequests.count)
}, by: { `dt.entity.datapower:webservice`, `dt.entity.datapower:instance` }, interval: 1m
| fieldsAdd activeResponseTime = if(requests[] > 0, lastResponseTime[], else: 0)
| fieldsKeep `dt.entity.datapower:webservice`, `dt.entity.datapower:instance`, activeResponseTime
| sort (arrayAvg(activeResponseTime)) desc
| limit 20

 

  • In the visualization, select activeResponseTime as the series to plot.
  • This shows the actual response time value only in intervals that had any requests; otherwise it’s zero.
  • Avoids the flat line effect and the limitations of arrayDelta (which only shows changes, not actual values).
  • The request counter and lastResponseTime are provided by the DataPower extension and share the same entity dimensions, so they align naturally in a single timeseries call.

Let me know if it helps you!
Best,
Anderson

Featured Posts