Hi Community !
I would like to have the detailed process and requirements to create a chart that will display the number of times a method has been invoked. The method is browsable but when I create an invocation measure then add it to a chart I've got no result.
PS : In the agents group App methods sensor is placed and active. I didn't specified any sensor rules in the system profile.
Should I add a sensor rule ?
Answer by Andreas G. ·
Well - the best practice is to only instrument methods that really bring you value, e.g: you need them to capture method arguments for Business Transactions or you need them for things like you want to achieve - knowing how often a method is invoked.
If you pick methods that are called VERY OFTEN but execute very fast than the "relative" overhead of dynaTrace for these methods can become substantial. We are now talking about methods that are called hundreds or thousands of times per PurePath. I hope your method is not one like this.
Anyway - you can use our CPU Sampling DAshlet to perform a regular CPU Sample. Let it run for a while under normal application load conditions. When you are done with the Sample and explore the results you will find an option that shows you the "dynaTrace Instrumentation Overhead". There you will find the hotspots of our own instrumented code
Hope this helps
Answer by Jean-rémi P. ·
Hi Andreas,
Thank you for your prompt answer, it's working well. By the way do you know if there is a pertinent way to compute the overhead of a sensor. Team are scared to deploy additionnal sensors.
Answer by Andreas G. ·
Hi
Check out the following screenshots that show you how you can create a method invocation measure. Key is that you need a Sensor becuase dynaTrace can only count method invocations in case the method is instrument. The wizard however does all of this for us
Now you need to make sure the Sensor is active. For .NET you need to restart your application, for Java you can also do a Hot Sensor Placement (or restart). From now on - PurePaths that will make a call to these methods - will show that method call. dynaTrace will start counting how often this method is invoked in the context of a PurePath and you can now chart it.
Be aware that
a) The method NEEDS to be called in the context of a PurePath. Easiest to verify this is to open the Methods dashlet. it shows you all the methods that are called in the PurePaths of the last XYZ Mins. If the method doesnt show up then either the sensor doesnt work or your method is not invoked as part of a PurePath.
b) You will only get this for PurePaths that were captured after this sensor is active -> no historical data will be visible
Hope this helps
Andi
JANUARY 15, 3:00 PM GMT / 10:00 AM ET