diff --git a/telemetry/instrumentation/otelslog/handler.go b/telemetry/instrumentation/otelslog/handler.go index a91275f..7d16b4e 100644 --- a/telemetry/instrumentation/otelslog/handler.go +++ b/telemetry/instrumentation/otelslog/handler.go @@ -30,17 +30,17 @@ const ( traceFlagsKey = "trace_flags" ) -type traceConfig struct { +type TraceConfig struct { recordStackTraceInSpan bool errorSpanLevel slog.Level } type TraceHandler struct { slog.Handler - tcfg *traceConfig + tcfg *TraceConfig } -func NewTraceHandler(w io.Writer, opts *slog.HandlerOptions, traceConfig *traceConfig) *TraceHandler { +func NewTraceHandler(w io.Writer, opts *slog.HandlerOptions, traceConfig *TraceConfig) *TraceHandler { if opts == nil { opts = &slog.HandlerOptions{} } diff --git a/telemetry/instrumentation/otelslog/option.go b/telemetry/instrumentation/otelslog/option.go index bba8597..1cf7d4f 100644 --- a/telemetry/instrumentation/otelslog/option.go +++ b/telemetry/instrumentation/otelslog/option.go @@ -33,14 +33,14 @@ func (fn option) apply(cfg *config) { type config struct { logger *cwslog.Logger - traceConfig *traceConfig + traceConfig *TraceConfig options []cwslog.Option } // defaultConfig default config func defaultConfig() *config { return &config{ - traceConfig: &traceConfig{ + traceConfig: &TraceConfig{ recordStackTraceInSpan: true, errorSpanLevel: slog.LevelError, },