Versions in this module Expand all Collapse all v0 v0.2.1 Oct 9, 2026 v0.2.0 Oct 8, 2026 Changes in this version + const FormatAuto + const FormatHuman + const FormatJSON + const LogFormatEnvVar + const LogLevelEnvVar + const SpanIDKey + const TraceIDKey + const TraceParentHeader + const TraceStateHeader + func Flush(ctx context.Context) error + func NewHandler(out io.Writer, platform string) slog.Handler + func NewLogger(out io.Writer, platform string) *slog.Logger + func SetFlusher(f Flusher) + func SetTracer(t Tracer) + func TracedCall(ctx context.Context, name string, attrs []Attr, ...) error + func Traced[T any](ctx context.Context, name string, attrs []Attr, ...) (T, error) + func WithLogger(ctx context.Context, l Logger) context.Context + func WithTraceContext(ctx context.Context, tc TraceContext) context.Context + type Attr struct + Key string + Value any + func Bool(key string, value bool) Attr + func Float64(key string, value float64) Attr + func Int(key string, value int) Attr + func Int64(key string, value int64) Attr + func String(key, value string) Attr + type Flusher func(ctx context.Context) error + type Logger = *slog.Logger + func LoggerFrom(ctx context.Context) Logger + type Span interface + Context func() SpanContext + End func() + RecordError func(err error) + SetAttributes func(attrs ...Attr) + type SpanContext struct + SpanID string + TraceID string + func (c SpanContext) Recorded() bool + type TraceContext map[string]string + func TraceContextFrom(ctx context.Context) (TraceContext, bool) + type Tracer interface + Start func(ctx context.Context, name string, attrs ...Attr) (context.Context, Span) + func CurrentTracer() Tracer