Home › OpenTelemetry (Observability)
The biggest payoff of OpenTelemetry is jumping from a slow span straight to the logs written during that span. That works when every log record carries traceid and spanid. Stack How logs get trace IDs .NET ILogger .WithLogging() (OTel logs) or ActivityTrackingOptions for console/JSON Python logging LoggingInstrumentor or a filter reading the current span Java (Logback/Log4j) agent injects traceid into MDC Node (pino/winston) instrumentation packages add the fields Practices Log in structured JSON with consistent keys (traceid, spanid, service.name). Prefer sending logs via OTLP (or the collector's filelog receiver) so resource attributes match traces. Use span events for things that only matter inside a trace; use logs for things operators search for.