Correlation
Trace ↔ Logs
Logs attach to a trace when log_entries.trace_id equals traces.trace_id. Span-level joins use matching span_id. Nothing else qualifies as DIRECT.
Join rules
- Trace → logs: stored
trace_idequality (OTLP / W3C id — not the internal row key). - Span → logs: stored
span_idequality. - Log search helpers:
trace:,span:.
How to emit
Pass IDs explicitly to createMydleLogger context, or rely on active OpenTelemetry span attachment when available. OTEL attribute aliases trace_id and span_id are promoted on ingest.
Limitations
- Never invent joins from timestamps, latency, or message text.
- Logs without
trace_iddo not appear on the trace — even if they happened “at the same time.”