Documentation
¶
Overview ¶
Package logging provides structured logging for Sentinel.
Index ¶
Constants ¶
View Source
const ( LevelDebug = slog.LevelDebug LevelInfo = slog.LevelInfo LevelWarn = slog.LevelWarn LevelError = slog.LevelError )
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Config ¶
Config configures the logger.
func DefaultConfig ¶
func DefaultConfig() *Config
DefaultConfig returns default logger configuration.
type Logger ¶
Logger wraps slog.Logger with convenience methods.
func FromContext ¶
FromContext retrieves the logger from context.
func (*Logger) WithComponent ¶
WithComponent returns a logger with a component field.
func (*Logger) WithFields ¶
WithFields returns a logger with additional fields.
Click to show internal directories.
Click to hide internal directories.