Documentation
¶
Overview ¶
Package logger provides minimal logging for Voxray. Uses std log; supports log level and optional JSON output.
Index ¶
- Variables
- func Configure(level string, json bool)
- func ConfigureFromConfig(level string, useJSON bool)
- func Debug(format string, args ...interface{})
- func Error(format string, args ...interface{})
- func Info(format string, args ...interface{})
- func WithSession(ctx context.Context, sessionID string) context.Context
Constants ¶
This section is empty.
Variables ¶
Functions ¶
func Configure ¶
Configure sets log level and JSON mode. Level is "debug", "info", or "error" (case-insensitive). When json is true, each log line is a JSON object: {"level":"info","msg":"..."}.
func ConfigureFromConfig ¶
ConfigureFromConfig sets log level and JSON mode from config-derived values.
func Debug ¶
func Debug(format string, args ...interface{})
Debug logs a debug message only if level is "debug".
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.