Documentation
¶
Index ¶
- Constants
- func FromContext(ctx context.Context, keysAndValues ...any) *slog.Logger
- func GetLogEntry(r *http.Request) *slog.Logger
- func IntoContext(ctx context.Context, logger *slog.Logger) context.Context
- func LogEntrySetField(r *http.Request, key string, value any)
- func LogEntrySetFields(r *http.Request, fields map[string]any)
- func NewLoggerForChi(logger *slog.Logger) func(http.Handler) http.Handler
- type StructuredLogger
- type StructuredLoggerEntry
Constants ¶
View Source
const (
KeyDetail = "detail"
)
Variables ¶
This section is empty.
Functions ¶
Types ¶
type StructuredLogger ¶
func (*StructuredLogger) NewLogEntry ¶
func (l *StructuredLogger) NewLogEntry(r *http.Request) middleware.LogEntry
type StructuredLoggerEntry ¶
func (*StructuredLoggerEntry) Panic ¶
func (l *StructuredLoggerEntry) Panic(v any, stack []byte)
Click to show internal directories.
Click to hide internal directories.