Allow custom Baggage-Item to Logger Metadata transformation
In some cases it might make sense to split a single Baggage value into several Logger.Metadata values. E.g. a SpanContext which contains things like traceID, spanID, and traceFlags might want to log these as individual metadata values. This is currently not possible, as LoggingContext uses the CustomStringConvertible conformance of the stored type to convert it to a single metadata value.
A workaround for this is to store traceID, spanID, and traceFlags as individual Baggage items, but this could potentially lead to inconsistencies where some of these values might be stored while others aren't. E.g. what happens when a spanID is stored but no traceID?
Originated here: https://github.com/slashmo/opentelemetry-swift/issues/6
That's one of the things to figure out how we want to answer for 1.0, assigning milestone
I believe this is solved with the https://github.com/apple/swift-log/pull/238 metadata providers -- users can do "whatever they want" basically.
I'm going to close this as done.