route/vendor/github.com/Xe/ln
Cadey Ratio 50c1deaa7d
change from vendor to dep
2017-10-06 08:29:20 -07:00
..
ex start adding go stdlib tracing 2017-10-01 06:54:56 -07:00
example change from vendor to dep 2017-10-06 08:29:20 -07:00
LICENSE change from vendor to dep 2017-10-06 08:29:20 -07:00
README.md change from vendor to dep 2017-10-06 08:29:20 -07:00
action.go update ln 2017-10-01 05:50:05 -07:00
context.go update ln 2017-10-01 05:50:05 -07:00
doc.go vendor: update ln 2017-08-12 09:33:02 -07:00
filter.go update ln 2017-10-01 05:50:05 -07:00
formatter.go update ln 2017-10-01 05:50:05 -07:00
logger.go update ln 2017-10-01 05:50:05 -07:00
logger_test.go change from vendor to dep 2017-10-06 08:29:20 -07:00
stack.go add ln, smux, kcp to deps 2017-03-26 12:50:20 -07:00

README.md

ln: The Natural Logger for Go

ln provides a simple interface to logging, and metrics, and obviates the need to utilize purpose built metrics packages, like go-metrics for simple use cases.

The design of ln centers around the idea of key-value pairs, which can be interpreted on the fly, but "Filters" to do things such as aggregated metrics, and report said metrics to, say Librato, or statsd.

"Filters" are like WSGI, or Rack Middleware. They are run "top down" and can abort an emitted log's output at any time, or continue to let it through the chain. However, the interface is slightly different than that. Rather than encapsulating the chain with partial function application, we utilize a simpler method, namely, each plugin defines an Apply function, which takes as an argument the log event, and performs the work of the plugin, only if the Plugin "Applies" to this log event.

If Apply returns false, the iteration through the rest of the filters is aborted, and the log is dropped from further processing.

Current Status: Initial Development / Concept

(c) 2015, Andrew Gwozdziewycz, BSD Licensed. See LICENSE for more info.