What problem does it solve?
Instrumenting a large Clojure codebase with OpenTelemetry tracing requires consistent span naming, attribute conventions, module boundary rules, and cyclic dependency avoidance. This Skill codifies Metabase's tracing conventions so spans are added correctly the first time.
Core Features & Use Cases
- Span Instrumentation Guidance: Wraps meaningful I/O boundaries (database queries, external API calls, batch processing) with the
tracing/with-span macro using correct groups, dot-notation span names, and namespaced keyword attributes.
- Module Architecture Enforcement: Ensures only the public
metabase.tracing.core namespace is required, prevents new tracing namespaces, and avoids cyclic load dependencies via requiring-resolve with literal quoted symbols.
- Safe SQL Attributes: Enforces use of
best-effort-sanitize-sql so HoneySQL queries appear in traces as parameterized statements without leaking data.
- Use Case: When adding trace coverage to a new sync task, the Skill walks through checking module
:uses config, adding the require, wrapping the I/O boundary, writing enabled/disabled tests, and running clj-kondo lint checks.
Quick Start
Add OpenTelemetry tracing spans to my Clojure namespace following the Metabase tracing conventions, then lint and test the changes.