Documentation
¶
Overview ¶
Package logging configures process-wide log output from the log config block. The text format keeps the historical plain lines. The json format writes one JSON object per line to stdout for container log collectors: standard-library log lines, slog records, HTTP access logs and GORM logs all go through the same handler.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AccessLog ¶
func AccessLog() gin.HandlerFunc
AccessLog is the json replacement for gin.Logger: one record per request.
func Setup ¶
Setup applies cfg to the process. It must run before the HTTP router and the database are initialised, so they pick up the chosen format.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.