Configuration-based
Stack Serverless Observability APM Agent Java
Use the trace_methods
configuration option to specify additional methods to instrument. You can match methods via wildcards in the package, class or method name, by their modifier (like public), by a particular annotation, and more. Because you donβt need to modify your source code, this makes it possible to monitor code in 3rd party libraries.
Be careful, itβs easy to overuse trace_methods
by matching too many methodsβ hurting both runtime and startup performance. Use in conjunction with span_min_duration
when setting for entire packages in order to avoid having too many spans in the APM app.
For more information, and examples, see the trace_methods
configuration reference.