You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Most (if not all) APM providers have the ability to connect logs with traces via a traceID and spanID on the log. The otelslog bridge (and by extension the others) should have the ability to set the top level (as defined in log contexts here) TraceID and SpanID. The sdk/log package supports this which makes working with the bridges particularly frustrating as you need to write a complex transformer for an otel collector in order to set these fields.
Proposed Solution
Have the convertRecord function be able to extract an attribute of trace_id and span_id and have them be set on the Record struct so that the top level attributes can be set.
Alternatives
Not doing this and continuing to have to write convoluted transformers for logs.
Prior Art
The sdk/log package handles this use case.
Additional Context
Add any other context or screenshots about the feature request here.
The text was updated successfully, but these errors were encountered:
While I agree with you that setting the span and trace IDs from attributes makes sense, I can't find trace_id or span_id as semantic conventions.
We'd need that before we can accept that kind of behavior.
along those lines is there an expected way to set the TraceID and SpanID fields for the otel log format? I've been trying to get it working via a transformer in the collector yaml, but it's tricky to get it right
Problem Statement
Most (if not all) APM providers have the ability to connect logs with traces via a traceID and spanID on the log. The otelslog bridge (and by extension the others) should have the ability to set the top level (as defined in log contexts here)
TraceID
andSpanID
. Thesdk/log
package supports this which makes working with the bridges particularly frustrating as you need to write a complex transformer for an otel collector in order to set these fields.Proposed Solution
Have the
convertRecord
function be able to extract an attribute oftrace_id
andspan_id
and have them be set on theRecord
struct so that the top level attributes can be set.Alternatives
Not doing this and continuing to have to write convoluted transformers for logs.
Prior Art
The
sdk/log
package handles this use case.Additional Context
Add any other context or screenshots about the feature request here.
The text was updated successfully, but these errors were encountered: