Documentation
¶
Index ¶
- func NewConsoleLogger() logz.Logger
- func NewConsoleLoggerStderr() logz.Logger
- func NewJSONLogger() logz.Logger
- type Logger
- func (l *Logger) Debug(data map[string]interface{})
- func (l *Logger) Err(data map[string]interface{})
- func (l *Logger) Info(data map[string]interface{})
- func (l *Logger) Log(level logz.LogLevel, data map[string]interface{})
- func (l *Logger) SetLevel(level logz.LogLevel) logz.Logger
- func (l *Logger) Trace(data map[string]interface{})
- func (l *Logger) Warn(data map[string]interface{})
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewConsoleLogger ¶
func NewConsoleLogger() logz.Logger
NewConsoleLogger initializes a logger with a github.com/rs/zerolog backend, configured to produce a nice colored output for usage in console applications (do not use this logger for production-grade high-log-throughput applications).
func NewConsoleLoggerStderr ¶
func NewConsoleLoggerStderr() logz.Logger
NewConsoleLoggerStderr is the same as NewConsoleLogger, but writes on stderr instead of stdout.
func NewJSONLogger ¶
func NewJSONLogger() logz.Logger
NewJSONLogger initializes a logger with a github.com/rs/zerolog backend, configured to produce json-formatted logs for high-log-throughput applications.
Types ¶
Click to show internal directories.
Click to hide internal directories.