Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions otel/log.go
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,8 @@ func NewLogrusHook(opts ...HookOpt) *LogrusHook {
return hook
}

// WithTraceIDField configures the hook to add the trace ID of the active span
// to log entries.
func WithTraceIDField(enabled bool) HookOpt {
return func(h *LogrusHook) {
h.enableTraceIDField = enabled
Expand Down
Loading