cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

This product reached the end of support date on March 31, 2021.

How to get Method Execution Time

bbaratono
Contributor

Hello,

I am having issues getting AppMon to record measures as I expect.

I create a measure of type "Method Time" and specify the Method/Class. I also put "1" in for severe threshold otherwise it doesn't generate anything.

The BT will give me the Purepaths associated with the measure and how long the purepath took.

I am looking for it to give me how long JUST the specified method took though, not the whole purepath in which that method was called.

Thoughts?

3 REPLIES 3

arturomr
Inactive

Hi,

The measure itself will give you what you want, method execution time. If you use it inside a BT (as filter, for instance) it will return all the pp invoking that concrete method.

Also, you can calculate on the BT (as calculate results) the method impact within the purepaths. In this case, you will need to decide what do you want to calculate, cause the aggretation choossen will make vary a lot from one to another (sum all the concrete methods per purepath will give the overall impact; average the avg per pp...and so on)

Hope this helps!

Regards

rajanikanthanka
Inactive

Hi,

Did you try using the measure Exec time under Methods? Try to chart this measure and then you can add it to BT.

exec-time.png

Represents the execution time for the declared method.

Thanks,
Rajani

JamesKitson
Dynatrace Leader
Dynatrace Leader

Do you care about sorting the PurePaths that have that method into a bucket you can analyze (which would require a business transaction) or are you just interested in the method execution time across all PurePaths?

In either case you'll want a methods->exec time measure set specifically for that method you're interested in (see below image). If you want this in your business transaction add it to the result measures field of the business transaction and it will be calculated across the PurePaths that meet your filter. If you are only interested in the execution time across all PurePaths (implicitly it will only be ones that call it of course) then just creating that measure outside of a business transaction would be enough (you don't need a BT for that).

James