This documentation has an index for AI agents at /llms.txt. A Markdown version of this page is available at https://explorer.opentelemetry.io/java-agent/instrumentation/methods.md.

Methods

OpenTelemetry Java agent instrumentation

Provides a flexible way to capture telemetry at the method level in JVM applications. By weaving instrumentation into targeted methods at runtime based on the "otel.instrumentation.methods.include" configuration property, it measures entry and exit points, execution duration and exception occurrences. The resulting data is automatically translated into OpenTelemetry traces.

  • Name: methods
  • Scope: io.opentelemetry.methods
  • Target versions: Java 8+

Configuration

OptionTypeDefaultDescription
otel.instrumentation.methods.includelistSemicolon-separated list of fully qualified class and method patterns to instrument.

Data

  • JSON: /data/javaagent/instrumentations/methods/methods-5dc3265f05a1.json
  • Explore: /java-agent/instrumentation/methods