-
Notifications
You must be signed in to change notification settings - Fork 5
Simple usage
Michael Kenney edited this page Aug 18, 2018
·
2 revisions
The simplest way to use bdlm/log
is with the exported package logger:
package main
import (
log "github.com/bdlm/log"
)
func main() {
log.WithFields(log.Fields{
"animal": "walrus",
}).Info("A walrus appears")
}
Available log method families are Debug
, Info
, Warn
(or Warning
), Error
, Panic
(recoverable), and Fatal
.
Which one will reach the other side of the river: The one who dreams of a raft, or the one that hitchhikes to the next bridge?