Name: go-mozlogrus
Owner: Mozilla Services
Description: A logging library which conforms to Mozilla's logging standard for logrus users.
Created: 2016-06-10 16:22:49.0
Updated: 2017-11-14 15:00:00.0
Pushed: 2018-05-02 20:41:36.0
Homepage: null
Size: 19
Language: Go
GitHub Committers
User | Most Recent Commit | # Commits |
---|
Other Committers
User | Most Recent Commit | # Commits |
---|
A logging library which conforms to Mozilla's logging standard for logrus.
go get go.mozilla.org/mozlogrus
age main
rt (
log "github.com/Sirupsen/logrus"
"go.mozilla.org/mozlogrus"
init() {
mozlogrus.Enable("ApplicationName")
main() {
log.WithFields(log.Fields{
"animal": "walrus",
"size": 10,
}).Info("A group of walrus emerges from the ocean")
son
run mozlogrus.go | jq
imestamp": 1487349663973687600,
ime": "2017-02-17T16:41:03Z",
ype": "app.log",
ogger": "ApplicationName",
ostname": "gator3",
nvVersion": "2.0",
id": 18061,
everity": 4,
ields": {
"animal": "walrus",
"msg": "A group of walrus emerges from the ocean",
"size": 10
init() {
mozlogrus.EnableFormatter(&mozlogrus.MozLogFormatter{
LoggerName: "ApplicationName",
Type: "udp datagram",
})