Documentation ¶
Overview ¶
Package greenery/zapbackend is a sample zap logging back-end for greenery based applications.
The zapbackend package implements the greenery library logging interface, using https://github.com/uber-go/zap/ as its back-end. Compared to the standard baselogging package, the zapbackend package supports proper structured logging as well as ANSI colored pretty logging.
The Custom function allows logging with arbitrary zapcore.Field data, if maximum speed and flexibility are required.
Index ¶
Constants ¶
const ( Debug = iota Info Warn Error )
The available logging levels for this backend are as follows and will map to the Debug, Info, Warn and Error zap methods.
Variables ¶
This section is empty.
Functions ¶
func PrettyLogger ¶
PrettyLogger returns a greenery Logger to be used for pretty logging
func StructuredLogger ¶
StructuredLogger returns a greenery Logger to be used for structured logging
Types ¶
This section is empty.