logging is now compatible with klog.

See https://git.kyleisom.net/lib/libklogger
This commit is contained in:
Kyle Isom
2016-04-01 15:08:55 -07:00
parent 419f23d655
commit d1452f54c0
8 changed files with 442 additions and 487 deletions

15
logging/doc.go Normal file
View File

@@ -0,0 +1,15 @@
// Package logging implements attribute-based logging. Log entries
// consist of timestamps, an actor and event string, and a mapping of
// string key-value attribute pairs. For example,
//
// log.Error("serialiser", "failed to open file",
// map[string]string{
// "error": err.Error(),
// "path": "data.bin",
// })
//
// This produces the output message
//
// [2016-04-01T15:04:30-0700] [ERROR] [actor:serialiser event:failed to open file] error=is a directory path=data.bin
//
package logging