scope-tracer
Visualize Java structured concurrency (StructuredTaskScope) task trees,
lifetimes, and cancellation propagation. Zero-code-change with a Java agent, or a
thin wrapper — either way you get a self-contained HTML report with SVG Gantt
timelines, built from a JFR recording. Targets JDK 26+.
What you get
- Per-scope Gantt timeline — what ran in parallel, at a glance
- Nested scopes rendered indented beneath the task that spawned them
- Critical-path highlighting — the task that determined total scope duration
- Failure and cancellation propagation, with exception details
- No server required — the report is a single self-contained HTML file
Zero-code-change tracing
java --enable-preview \
-javaagent:scope-tracer-agent-VERSION-agent.jar \
-XX:StartFlightRecording=filename=myapp.jfr,dumponexit=true \
-cp <your-classpath> com.example.MyApp
Any JDK 26+ application using StructuredTaskScope gets traced —
no source changes. See the
README
for the library wrapper (TracedScope), capture filters/sampling for
production use, and full setup instructions.