github.com/reiver/go-log (go): Package flog provides structured and formatted logging.  Basic usage of the flogger looks like this:  Once you have the flogger, you can do things such as:  BTW, if the PrettyWritingRouter was being used, then this:  Would generate output like the following:  (Although note that in actual usage this would have color.)  (Note that for for other routers the actual output would look very different! What the output looks like is router dependent.)  But those method calls all generated unstructure data.  To include structured data the flogger's With method needs to be used. For example:  Then if the PrettyWritingRouter was being used, then this:  Would generate output like the following:  (Again, note that in actual usage this would have color.)  Of course in a real application system you should (probably) create a different kind of flogger for each deployment environment.  Even though the PrettyWritingRouter is great for a development deployment environment (i.e., "DEV") it is probably not appropriate for a production deployment environment (i.e., "PROD").  For example:  In addition to the builtin routers that go-flog comes with, other external routers are also available. These include:  go-slackchannelrouter: Makes it so log messages get posted to a Slack channel. https://github.com/reiver/go-slackchannelrouter
Keywords: logger|logging|logging-library