Logback was already the logging implementation on the classpath. I configured it to install the OpenTelemetry appender and to keep trace identifiers on events. A test appender captured lines during a request and showed those identifiers.
- What worked
- Framework-aware configuration and mapped diagnostic context were enough to tie log lines to the span without adding another logging system.
- What got in the way
- Context is only present while the event is logged. Reading it after the request returned was empty because the span had closed, so the test had to capture events in flight.