feat: emit TaskBlock events for JVM blocking states#665
Conversation
CI Test ResultsRun: #29571012127 | Commit:
Status Overview
Legend: ✅ passed | ❌ failed | ⚪ skipped | 🚫 cancelled Summary: Total: 32 | Passed: 32 | Failed: 0 Updated: 2026-07-17 10:05:16 UTC |
1beeda2 to
38efbf8
Compare
Benchmark Results (commit 38efbf8)Pipeline: https://gitlab.ddbuild.io/DataDog/apm-reliability/benchmarking-platform/-/pipelines/125051342 Commit:
|
| Benchmark | JDK | Latest | Dev | Δ (dev vs latest) | Issues L/D |
|---|---|---|---|---|---|
| akka-uct | 21 | ✅ 10365 ms (21 iters) | ✅ 10195 ms (21 iters) | ≈ -1.6% (±11.4%) | — / — |
| akka-uct | 25 | ✅ 8859 ms (24 iters) | ✅ 8925 ms (24 iters) | ≈ +0.7% (±10.1%) | — / — |
| finagle-chirper | 21 | ✅ 5945 ms (33 iters) | ✅ 5953 ms (33 iters) | ≈ +0.1% (±24.9%) | |
| finagle-chirper | 25 | ✅ 5495 ms (36 iters) | ✅ 5431 ms (36 iters) | ≈ -1.2% (±24.2%) | |
| fj-kmeans | 21 | ✅ 2719 ms (68 iters) | ✅ 2830 ms (66 iters) | 🔴 +4.1% | — / — |
| fj-kmeans | 25 | ✅ 2737 ms (68 iters) | ✅ 2815 ms (66 iters) | 🔴 +2.8% | — / — |
| future-genetic | 21 | ✅ 2114 ms (88 iters) | ✅ 2140 ms (87 iters) | ≈ +1.2% (±2.7%) | — / — |
| future-genetic | 25 | ✅ 2080 ms (90 iters) | ✅ 2126 ms (88 iters) | ≈ +2.2% (±2.5%) | — / — |
| naive-bayes | 21 | ✅ 1299 ms (131 iters) | ✅ 1232 ms (139 iters) | ≈ -5.2% (±31.9%) | — / — |
| naive-bayes | 25 | ✅ 997 ms (172 iters) | ✅ 1004 ms (170 iters) | ≈ +0.7% (±31.8%) | — / — |
| reactors | 21 | ✅ 16202 ms (15 iters) | ✅ 15908 ms (15 iters) | ≈ -1.8% (±7.6%) | — / — |
| reactors | 25 | ✅ 18524 ms (15 iters) | ✅ 18484 ms (15 iters) | ≈ -0.2% (±3.9%) | — / — |
Internal counter details (ddprof)
ddprof internal counters, latest / dev (✅ = 0, · = unavailable):
| Benchmark | JDK | Dropped rec | Dropped jvmti | Dropped trace | Skipped WC | AGCT fail | Unwind fail |
|---|---|---|---|---|---|---|---|
| akka-uct | 21 | ✅ / ✅ | ✅ / ✅ | 2 / ✅ | 2045 / 1958 | ✅ / ✅ | ✅ / ✅ |
| akka-uct | 25 | ✅ / ✅ | ✅ / ✅ | ✅ / 3 | 2353 / 2059 | ✅ / ✅ | ✅ / ✅ |
| finagle-chirper | 21 | ✅ / ✅ | ✅ / ✅ | 6 / 2 | 8437 / 8382 | ✅ / ✅ | ✅ / ✅ |
| finagle-chirper | 25 | ✅ / ✅ | ✅ / ✅ | ✅ / 2 | 8800 / 8439 | ✅ / ✅ | ✅ / ✅ |
| fj-kmeans | 21 | ✅ / ✅ | ✅ / ✅ | 2 / 2 | 1248 / 1279 | ✅ / ✅ | ✅ / ✅ |
| fj-kmeans | 25 | ✅ / ✅ | ✅ / ✅ | 4 / 1 | 1262 / 1271 | ✅ / ✅ | ✅ / ✅ |
| future-genetic | 21 | ✅ / ✅ | ✅ / ✅ | ✅ / ✅ | 2963 / 2980 | ✅ / ✅ | ✅ / ✅ |
| future-genetic | 25 | ✅ / ✅ | ✅ / ✅ | 2 / 3 | 2955 / 2936 | ✅ / ✅ | ✅ / ✅ |
| naive-bayes | 21 | ✅ / ✅ | ✅ / ✅ | 3 / 7 | 3466 / 3539 | ✅ / ✅ | ✅ / ✅ |
| naive-bayes | 25 | ✅ / ✅ | ✅ / ✅ | 5 / 1 | 3478 / 3531 | ✅ / ✅ | ✅ / ✅ |
| reactors | 21 | ✅ / ✅ | ✅ / ✅ | ✅ / ✅ | 1700 / 1609 | ✅ / ✅ | ✅ / ✅ |
| reactors | 25 | ✅ / ✅ | ✅ / ✅ | ✅ / ✅ | 1905 / 1873 | ✅ / ✅ | ✅ / ✅ |
Reliability & Chaos Results✅ All reliability & chaos checks passed Pipeline: https://gitlab.ddbuild.io/DataDog/java-profiler/-/pipelines/125035442 |
38efbf8 to
cdb8274
Compare
Benchmark Results (commit cdb8274)Pipeline: https://gitlab.ddbuild.io/DataDog/apm-reliability/benchmarking-platform/-/pipelines/125162043 Commit:
|
| Benchmark | JDK | Latest | Dev | Δ (dev vs latest) | Issues L/D |
|---|---|---|---|---|---|
| finagle-chirper | 21 | ✅ 5956 ms (33 iters) | ✅ 6031 ms (33 iters) | ≈ +1.3% (±24.8%) | |
| finagle-chirper | 25 | ✅ 5457 ms (36 iters) | ✅ 5444 ms (36 iters) | ≈ -0.2% (±23.9%) | |
| fj-kmeans | 21 | ✅ 2683 ms (70 iters) | ✅ 2821 ms (66 iters) | 🔴 +5.1% | — / — |
| fj-kmeans | 25 | ✅ 2786 ms (67 iters) | ✅ 2839 ms (66 iters) | ≈ +1.9% (±2.7%) | — / — |
| future-genetic | 21 | ✅ 2063 ms (90 iters) | ✅ 2095 ms (89 iters) | ≈ +1.6% (±2.6%) | — / — |
| future-genetic | 25 | ✅ 2072 ms (90 iters) | ✅ 2125 ms (87 iters) | ≈ +2.6% (±2.6%) | — / — |
| naive-bayes | 21 | ✅ 1257 ms (135 iters) | ✅ 1250 ms (136 iters) | ≈ -0.6% (±32.8%) | — / — |
| reactors | 21 | ✅ 16137 ms (15 iters) | ✅ 15974 ms (15 iters) | ≈ -1% (±7.5%) | — / — |
| reactors | 25 | ✅ 18395 ms (15 iters) | ✅ 18505 ms (15 iters) | ≈ +0.6% (±4.4%) | — / — |
Internal counter details (ddprof)
ddprof internal counters, latest / dev (✅ = 0, · = unavailable):
| Benchmark | JDK | Dropped rec | Dropped jvmti | Dropped trace | Skipped WC | AGCT fail | Unwind fail |
|---|---|---|---|---|---|---|---|
| akka-uct | 21 | ✅ / ✅ | ✅ / ✅ | ✅ / ✅ | ✅ / ✅ | ✅ / ✅ | ✅ / ✅ |
| akka-uct | 25 | ✅ / ✅ | ✅ / ✅ | 1 / 1 | 2260 / 2182 | ✅ / ✅ | ✅ / ✅ |
| finagle-chirper | 21 | ✅ / ✅ | ✅ / ✅ | 4 / 3 | 8741 / 8673 | ✅ / ✅ | ✅ / ✅ |
| finagle-chirper | 25 | ✅ / ✅ | ✅ / ✅ | 1 / ✅ | 8238 / 8373 | ✅ / ✅ | ✅ / ✅ |
| fj-kmeans | 21 | ✅ / ✅ | ✅ / ✅ | 4 / 2 | 1241 / 1256 | ✅ / ✅ | ✅ / ✅ |
| fj-kmeans | 25 | ✅ / ✅ | ✅ / ✅ | 2 / ✅ | 1287 / 1282 | ✅ / ✅ | ✅ / ✅ |
| future-genetic | 21 | ✅ / ✅ | ✅ / ✅ | 2 / 1 | 2971 / 2981 | ✅ / ✅ | ✅ / ✅ |
| future-genetic | 25 | ✅ / ✅ | ✅ / ✅ | 1 / 1 | 2968 / 2956 | ✅ / ✅ | ✅ / ✅ |
| naive-bayes | 21 | ✅ / ✅ | ✅ / ✅ | 5 / 3 | 3468 / 3474 | ✅ / ✅ | ✅ / ✅ |
| naive-bayes | 25 | ✅ / ✅ | ✅ / ✅ | 9 / 3 | 3464 / 3465 | ✅ / ✅ | ✅ / ✅ |
| reactors | 21 | ✅ / ✅ | ✅ / ✅ | 1 / 2 | 1531 / 1536 | ✅ / ✅ | ✅ / ✅ |
| reactors | 25 | ✅ / ✅ | ✅ / ✅ | 1 / ✅ | 1857 / 1856 | ✅ / ✅ | ✅ / ✅ |
Benchmark Results (commit e13ec27)Pipeline: https://gitlab.ddbuild.io/DataDog/apm-reliability/benchmarking-platform/-/pipelines/125211559 Commit: ✅ Within expected boundariesNo significant runtime deltas (all within run-to-run noise) and no internal-counter outliers. Runtime details (per benchmark × JDK)
Internal counter details (ddprof)ddprof internal counters, latest / dev (✅ = 0, · = unavailable):
|
e13ec27 to
c111812
Compare
Benchmark Results (commit c111812)Pipeline: https://gitlab.ddbuild.io/DataDog/apm-reliability/benchmarking-platform/-/pipelines/125236325 Commit: ✅ Within expected boundariesNo significant runtime deltas (all within run-to-run noise) and no internal-counter outliers. Runtime details (per benchmark × JDK)
Internal counter details (ddprof)ddprof internal counters, latest / dev (✅ = 0, · = unavailable):
|
What does this PR do?:
Adds JVM TaskBlock producers for
LockSupport.parkand monitor contention/wait states, wiring JVM state transitions into the synchronous TaskBlock recording API.Motivation:
Common JVM blocking operations can be represented as TaskBlock events instead of relying on wall-clock signals against blocked threads.
Additional Notes:
Virtual threads are not explicitly emitted by this PR. This change focuses on platform-thread JVM blocking states exposed through the existing VM entry paths.
How to test the change?:
Automated coverage includes native park-state tests and Java integration tests for park, monitor wait, monitor contention, JVMTI-backed variants, and combined wall-clock mitigation behavior.
./.claude/commands/build-and-summarize testDebugFor Datadog employees:
dd:platform-security-reviewskill, or file a request via the PSEC review form).bewairealso runs automatically on every PR.