Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Config ¶
type Config struct {
// Next defines a function to skip this middleware.
Next func(ctx *fiber.Ctx) bool
// Logger is a *zerolog.Logger that writes the logs.
//
// Default: log.Logger.Output(zerolog.ConsoleWriter{Out: os.Stderr})
Logger *zerolog.Logger
TimeLayout string
LogUsername string // log from context username parameter (by default set to 'username'
LogUserAgent bool // log user agent
LogForwardedFor bool // log X-Forwarded-For (if behing a balancer) or repote IP
LogHost bool // log incommig host (in request)
TagReqHeader []string
TagRespHeader []string
Tags []string // log from context user parameter with keys from tags slice
}
Config defines the config for logger middleware.
Click to show internal directories.
Click to hide internal directories.
