We're dealing with some extremely slow database queries that aren't showing accurate aggregation metrics in the Purepath. In one example, it will show 1 x DB query in the argument column and 0.03 for the Exec Total [ms] column.
If I turn off JDBC aggregation, it shows 70,000ms in the purepath tree Exec Total column.
This discrepancy is making it very difficult to troubleshoot issues and find the slow query. A similar post here https://answers.dynatrace.com/spaces/148/uem-open-q-a_2/questions/106485/database-dashlet-exec-avg-t... looks like the same issue at the bottom, where @Andreas G. said the database time metric should not change just by enabling aggregation.
With aggregation enabled, the Node Details show .03 in the Time Details Exec column, and the 70,000 under the Statement Aggregation Details Execute row. But the purepath tree only shows the .03.
So with aggregation disabled, if I see this:
|Argument||Exec Total (ms)|
|SELECT * from product_prices||100.00|
|SELECT * from product_prices||300.00|
I would expect the aggregation to show this:
|Argument||Exec Total (ms)|
|2 x SELECT * from product_prices||400.00|
But instead it's picking some other java execution time and showing .02ms.
Here's a better view of the query details: the purepath tree is displaying the Execution Time of .03ms, but the actual time is 130 seconds.
If I disable JDBC aggregation, then the purepath shows the full response time for the query.
Solved! Go to Solution.
As I understand there is no chance that you have couple of hundreds of DB statement execution? In such case aggregation would indeed be result of sum. I’m wondering if in other case actually problem is with slow query. Maybe problem is with connection acquisition and during aggregation it’s summed up somehow. How your connection pools looks like?
Unfortunately not, we are looking at queries that are only executed once in the transaction. The purepath shows some miniscule number for the query, but drilling down to the database dashlet or right-clicking the query and viewing details shows a drastically different number.
Ok one more question, when you have aggregation disabled and query is presented as fast one, overall response time of this pure path is indeed 70s? If yes, did you tried using cpu sampling or show all nodes option to drill down about root cause then?
Ask as many questions as you like, we could use any help!
If we disable aggregation, the query is presented with the correct response time.
No matter the aggregation setting, the purepath overall always shows the correct response time.
We know the root cause is the slow database query based on Node Details and the Drill down into the database dashlet. Our problem is getting the actual query response time to show up in the purepath with aggregation enabled.
Based on the 2015 forum post I linked, they were having the same problem with the DB Time measure fluctuating based on the aggregation setting. I haven't kept aggregation disabled long enough to see if this is the case for us, but seems like the same issue.
So what Incan suggest to you is rising support ticket. Attach there two purepaths, one with aggregation one without. Only one Idea except that I have is being sure that you have newest AppMon version. Second is checking if there is difference when you use classic or AppMon agents. The second one is build on top of OneAgent binaries used in dynatrace so it may work in different way than classic one.