Documentation ¶
Index ¶
- Variables
- func ConfigureGlobalLogger(lvl Level, fmt Format)
- func Debug() *zerolog.Event
- func Error() *zerolog.Event
- func Fatal() *zerolog.Event
- func Info() *zerolog.Event
- func Panic() *zerolog.Event
- func SendToStdout(output string)
- func Warn() *zerolog.Event
- type ContextualLogger
- func (el *ContextualLogger) Debug() *zerolog.Event
- func (el *ContextualLogger) Error() *zerolog.Event
- func (el *ContextualLogger) Fatal() *zerolog.Event
- func (el *ContextualLogger) Info() *zerolog.Event
- func (el *ContextualLogger) Panic() *zerolog.Event
- func (el *ContextualLogger) Warn() *zerolog.Event
- type Format
- type Level
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // InfoEnabled - check if this level is enabled InfoEnabled bool // DebugEnabled - check if this level is enabled DebugEnabled bool // WarnEnabled - check if this level is enabled WarnEnabled bool // ErrorEnabled - check if this level is enabled ErrorEnabled bool // FatalEnabled - check if this level is enabled FatalEnabled bool // PanicEnabled - check if this level is enabled PanicEnabled bool )
Functions ¶
func ConfigureGlobalLogger ¶
ConfigureGlobalLogger - configures the logger globally
func SendToStdout ¶
func SendToStdout(output string)
SendToStdout - logs a output with no log format
Types ¶
type ContextualLogger ¶ added in v1.29.3
type ContextualLogger struct {
// contains filtered or unexported fields
}
ContextualLogger - a struct containing all valid event loggers (each one can be null if not enabled)
func CreateContextualLogger ¶ added in v1.29.3
func CreateContextualLogger(keyValues ...string) *ContextualLogger
CreateContextualLogger - creates loggers with context
func (*ContextualLogger) Debug ¶ added in v1.29.3
func (el *ContextualLogger) Debug() *zerolog.Event
Debug - returns the event logger using the configured context
func (*ContextualLogger) Error ¶ added in v1.29.3
func (el *ContextualLogger) Error() *zerolog.Event
Error - returns the event logger using the configured context
func (*ContextualLogger) Fatal ¶ added in v1.29.3
func (el *ContextualLogger) Fatal() *zerolog.Event
Fatal - returns the event logger using the configured context
func (*ContextualLogger) Info ¶ added in v1.29.3
func (el *ContextualLogger) Info() *zerolog.Event
Info - returns the event logger using the configured context
func (*ContextualLogger) Panic ¶ added in v1.29.3
func (el *ContextualLogger) Panic() *zerolog.Event
Panic - returns the event logger using the configured context
func (*ContextualLogger) Warn ¶ added in v1.29.3
func (el *ContextualLogger) Warn() *zerolog.Event
Warn - returns the event logger using the configured context
type Level ¶
type Level string
Level - type
const ( // INFO - log level INFO Level = "info" // DEBUG - log level DEBUG Level = "debug" // WARN - log level WARN Level = "warn" // ERROR - log level ERROR Level = "error" // FATAL - log level FATAL Level = "fatal" // PANIC - log level PANIC Level = "panic" // NONE - log level NONE Level = "none" // SILENT - log level SILENT Level = "silent" )
Click to show internal directories.
Click to hide internal directories.