Documentation ¶
Index ¶
- Constants
- func Debugf(format string, args ...interface{})
- func Errorf(format string, args ...interface{})
- func Errorw(message string, args ...interface{})
- func Fatalw(message string, args ...interface{})
- func Infof(format string, args ...interface{})
- func Infow(message string, args ...interface{})
- func NewLogger(l Logger)
- func Warnf(format string, args ...interface{})
- func Warnw(message string, args ...interface{})
- type Fields
- type Logger
Constants ¶
View Source
const ( // Debug has verbose message Debug = "debug" // Info is default log level Info = "info" // Warn is for logging messages about possible issues Warn = "warn" // Error is for logging errors Error = "error" // Fatal is for logging fatal messages. The sytem shutsdown after logging the message. Fatal = "fatal" )
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Fields ¶
type Fields map[string]interface{}
Fields defines key value pair for structured logging when usig WithFields method.
type Logger ¶
type Logger interface { Debugf(format string, args ...interface{}) Infof(format string, args ...interface{}) Warnf(format string, args ...interface{}) Errorf(format string, args ...interface{}) Infow(message string, args ...interface{}) Warnw(message string, args ...interface{}) Errorw(message string, args ...interface{}) Fatalw(message string, args ...interface{}) WithFields(keyValues Fields) Logger }
Logger is our contract for the logger
Click to show internal directories.
Click to hide internal directories.