By default, the APM Insight agent instruments application transactions, supported classes and methods, and web frameworks. To minimize overhead on the application, certain methods and frameworks are not instrumented by default.
Custom instrumentation allows you to configure additional methods, classes, or frameworks for monitoring, providing greater visibility into application performance and transaction traces.
Custom instrumentation is useful in the following scenarios:
Note: Web Client custom instrumentation is supported only for Java and .NET Core agents. For Ruby and Node.js applications, use the respective agent APIs to configure custom instrumentation: Ruby and Node.js.
These configurations apply to all instances of an APM Insight application. To configure instance-specific custom instrumentation, use the Java agent API or .NET agent API, depending on your application platform.
Follow these steps to configure custom instrumentation:
JSON format
Use the following syntax to specify the fully qualified class name, method names, and component name:
{
"Fully qualified ClassName": {
"MethodName1": "ComponentName",
"MethodName2": "ComponentName"
}
}{
"com.sample.web.tasks.ModelUpdateHandler": {
"doHandle": "MODEL_UPDATE",
"update": "MODEL_UPDATE"
}
}Use Beautify JSON to format the JSON input and Reset to clear your changes.
Text format
Use the following syntax to specify the fully qualified class name, method names, and component name. Separate the method names with commas.
Fully qualified ClassName : methodNames separated by comma(,) : Component Namecom.sample.web.tasks.ModelUpdateHandler : doHandle, update : MODEL_UPDATE
com.sample.web.services.SystemCheck : doCheck, isHealthy :
com.sample.web.store.DataModifier : : MODIFIER
com.sample.web.utils.FileUtils : :Note: Specify fully qualified class names in the following formats:
Java:com/appmanager/apminsight/agent/JavaAgent
.NET Core:Com.Appmanager.Apminsight.Agent.DotAgent

The following screenshots illustrate the transaction trace before and after custom instrumentation with the Java agent.
Before:

After:

It allows us to track crucial metrics such as response times, resource utilization, error rates, and transaction performance. The real-time monitoring alerts promptly notify us of any issues or anomalies, enabling us to take immediate action.
Reviewer Role: Research and Development