Observability
Capture compiled SQL, tag queries, and debug join and metric planning in production.
The most useful artifact for debugging is the compiled SQL.
Capture Compiled SQL
- Use
--dry-runwhen available to inspect generated SQL. - In services, log:
- the semantic query inputs
- the resolved models/dimensions/metrics
- the compiled SQL
Instrumentation Comments
Sidemantic can include -- sidemantic: comments in compiled SQL. These are used by Pre-Agg Recommendations.
Debug Workflow
- Reproduce the semantic query.
- Inspect compiled SQL.
- Validate join path and metric aggregation strategy.
- Compare to a baseline query at a known grain.