A tiny middleware for negroni et al. Writes logs in json which makes it easy to get them into elasticsearch.
go get github.com/sontags/logger
Easy:
package main
import (
// ...
"github.com/codegangsta/negroni"
"github.com/sontags/logger"
)
// ...
func main() {}
// ...
n := negroni.New(
negroni.NewRecovery(),
logger.NewLogger(),
)
// ...
}