Use when you need to implement or improve distributed tracing with OpenTelemetry in Java — including trace/span modeling, context propagation, semantic conventions, span attributes/events/status, sampling strategy, baggage usage, privacy safeguards, and backend integration with OTLP collectors. This should trigger for requests such as Improve tracing; Apply OpenTelemetry tracing; Add distributed tracing; Refactor tracing instrumentation; Instrument Java services with OpenTelemetry spans. Part of
SkillScore95Maintained
Automatic
◆DevOps & SRE pack
Last verified 8/20/2026
What it changes
Passed 20 of 21 test cases with the skill, and 14 of 21 without it.
Without skill68%
With skill95%
Checks it passed that the model alone missed
The response includes `clean verify` as a Maven verification command.
The response cautions against high-cardinality dynamic values in search attributes.
The response prioritizes propagating OpenTelemetry context across task executor boundaries.
6 fixed15 passed either way1 still failing0 broke
Pass-rate lift
+27 pp
Tokens
+2%
Agent turns
0%
Response time
-23%
Model gemini-3.6-flashMeasured 8/20/2026v121 of 22 cases passed with skill · 21 comparable
Tokens, turns and time describe resource use, not a dollar price.
See it in action
One of 5 test cases the skill fixed. Same model, same prompt, with and without the skill.
1 of 5
Prompt
We have a Java Spring Boot microservice that calls external REST APIs and dispatches background tasks via an ExecutorService. Trace IDs are currently getting lost when calls cross HTTP or thread boundaries. Could you update our service classes to properly instrument OpenTelemetry tracing across these REST and async boundaries? Please provide the refactored Java code along with instructions on how to validate the changes.
What was checked, without and with the skill
Checked
Without skill
With skill
The response includes `clean verify` as a Maven verification command.
Missed
Passed
The response prioritizes context propagation across thread and HTTP boundaries over creating detailed custom span attributes.
Passed
Passed
case-01 · gemini-3.6-flash · 8/20/2026 · answers are capped and redacted
What's inside
The instructions your model reads when the skill loads.
SKILL.md55 lines2 files
Java Distributed Tracing with OpenTelemetry
Implement robust distributed tracing in Java with OpenTelemetry by modeling meaningful spans, preserving context propagation, and instrumenting critical business and infrastructure paths with low-overhead, privacy-safe telemetry.
What is covered in this Skill?
OpenTelemetry tracing fundamentals for Java services
Span design: boundaries, parent/child relationships, and operation naming
Context propagation across HTTP, messaging, async tasks, and thread boundaries
Semantic conventions and stable attribute naming
Error/status/event recording best practices
Sampling strategy and performance/cost trade-offs
Privacy and security controls for trace attributes
Testing and verification of trace propagation and span correctness
Scope: Distributed tracing quality in application and integration layers, focused on diagnosability, consistency, and operational safety.
Constraints
Tracing instrumentation must preserve context correctly and avoid leaking sensitive data. Over-instrumentation and high-cardinality attributes can harm cost and signal quality.
PROPAGATION FIRST: Ensure context propagation across all sync/async boundaries before adding extra span detail
NO SENSITIVE DATA: Never store secrets, credentials, tokens, raw payloads, or PII in span attributes/events
LOW CARDINALITY ATTRIBUTES: Avoid unbounded values in attributes that are used for aggregation/search
VERIFY: Run ./mvnw clean verify or mvn clean verify after applying tracing changes
When to use this skill
Improve tracing
Apply OpenTelemetry tracing
Add distributed tracing
Refactor tracing instrumentation
Instrument Java services with OpenTelemetry spans
Workflow
Define trace model and critical flows
Identify high-value request and async flows, define operation boundaries, and choose span names/attributes aligned with semantic conventions.
Use when you need to review, improve, or build Spring Boot 4.0.x applications — including proper usage of @SpringBootApplication, component annotations (@Controller, @Service, @Repository), bean definition and scoping, configuration classes and @ConfigurationProperties (with @Validated), component scanning, conditional configuration and profiles, constructor injection, @Primary and @Qualifier for multiple beans of the same type, bean minimization, graceful shutdown, virtual threads, Jakarta EE n