09 Dec 2025 12:05 PM
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.
Wasnt sure if this was a DQL question or a dashboard question pertaining to visualization options so posted here.
10 Dec 2025 02:30 AM
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
Let me know if it helps you!
Best,
Anderson
Featured Posts