The Elastic Distribution of OpenTelemetry Java (EDOT Java) is a customized version of the OpenTelemetry Java agent. Use EDOT Java to start the OpenTelemetry SDK with your Java application, and automatically capture tracing data, performance metrics, and logs. Traces, metrics, and logs can be sent to any OpenTelemetry Protocol (OTLP) collector you choose.
With EDOT Java you have access to all the features of the OpenTelemetry Java agent plus:
Ready to try out EDOT Java? Follow the step-by-step instructions in Get started.
We welcome your feedback! You can reach us by opening a GitHub issue or starting a discussion thread on the Elastic Discuss forum.
Use the -javaagent:
JVM argument with the path to agent jar.
java -javaagent:/path/to/agent.jar \
-jar myapp.jar
Execute ./gradlew assemble
, the agent binary will be in ./agent/build/libs/elastic-otel-javaagent-${VERSION}.jar
where ${VERSION}
is the current project version set in version.properties
.
You can run the tests locally using ./gradlew test
. You can optionally specify the
-PtestJavaVersion=8
hotspot
or openJ9
): -PtestJavaVM=openj9
You don't need to have a corresponding JVM installed, gradle automatically will download a matching one.
The agent enables the following resource attributes providers from opentelemetry-java-contrib
The attributes for cloud providers are captured asynchronously to prevent application startup overhead due to calling an internal metadata API.
Set OTEL_INFERRED_SPANS_ENABLED=true
to enable.
See inferred spans for more details
The agent captures the stacktraces of spans to help identify code paths that triggered them.
The stacktrace is stored in the code.stacktrace
attribute.
The minimum span duration can be configured with elastic.otel.java.span-stacktrace.min.duration
(defaults to 5ms
).
Implementation has been contributed upstream in the opentelemetry-java-contrib repository,
in the span-stacktrace
folder.
Experimental runtime metrics are enabled by default.
Set otel.instrumentation.runtime-telemetry.emit-experimental-telemetry
to false
to disable them.
The Elastic Distribution of OpenTelemetry Java is licensed under Apache License, Version 2.0.