-
Notifications
You must be signed in to change notification settings - Fork 324
Open
Labels
comp: native-imageGraalVM native-imageGraalVM native-imagetype: bugBug report and fixBug report and fix
Description
Tracer Version(s)
1.58.2
Java Version(s)
21
JVM Vendor
Oracle GraalVM
Bug Report
Summary
dd-trace-java v1.58.2 breaks GraalVM native image builds. v1.58.1 works correctly. The issue appears to be caused by the "Bump java profiler to 1.36.1" change in v1.58.2.
Environment
- dd-trace-java version: v1.58.2 (broken), v1.58.1 (works)
- GraalVM version: GraalVM 21.0.5+9.1
- Quarkus version: 3.28.4
- OS: macOS (also reproduced in Linux CI environment)
Steps to Reproduce
- Configure Quarkus native build with dd-java-agent attached via
-J-javaagent:quarkus.native.additional-build-args=\ -J-javaagent:${AGENT_PATH:/path/to/dd-java-agent.jar},\ -J-Ddd.logs.injection=true
- Build native image with dd-java-agent v1.58.2
- Build fails
Error Output
Stage 1 - ClassNotFoundException:
[dd.trace ...] ERROR datadog.common.version.VersionInfo - No version file found
Error: Class initialization of com.datadoghq.profiler.ThreadContext failed.
Caused by: java.lang.ClassNotFoundException: com.datadoghq.profiler.BufferWriter9
Stage 2 - After adding --initialize-at-run-time=com.datadoghq.profiler.ThreadContext:
The build progresses further but then crashes with a SIGBUS signal:
# A fatal error has been detected by the Java Runtime Environment:
# SIGBUS (0xa) at pc=0x..., pid=..., tid=...
Error: Image build request for 'application-runner' ... failed with exit status 134
Version Comparison
| Agent Version | Release Date | Native Build |
|---|---|---|
| v1.57.0 | Dec 18, 2025 | ✅ SUCCESS |
| v1.58.1 | Jan 21, 2026 | ✅ SUCCESS |
| v1.58.2 | Jan 23, 2026 | ❌ FAIL |
Root Cause Analysis
The v1.58.2 release notes mention "Bump java profiler to 1.36.1". This profiler update appears to have introduced classes or initialization patterns incompatible with GraalVM's native-image static analysis.
Workaround
Pin to v1.58.1 or earlier until this is fixed.
Expected Behavior
See bug report. Expecting it to not fail.
Reproduction Code
No response
Metadata
Metadata
Assignees
Labels
comp: native-imageGraalVM native-imageGraalVM native-imagetype: bugBug report and fixBug report and fix