log

package
v1.6.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 7, 2023 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetEncoder

func GetEncoder() zapcore.Encoder

GetEncoder 将日志消息编码为指定的格式 @return zapcore.Encoder 返回Encoder

func GetLoggerWriter

func GetLoggerWriter(config *config.Log) zapcore.WriteSyncer

GetLoggerWriter return writerSyncer @param *app.Log config 日志配置信息 @return zapcore.WriteSyncer 返回一个日志记录器

func GinLogger

func GinLogger() gin.HandlerFunc

GinLogger 接收gin框架默认的日志 @return gin.HandlerFunc 返回中间件上下文

func InitZapLogs

func InitZapLogs(config *config.Log, mode string) (err error)

InitZapLogs 初始化日志配置 @param *app.Log config 日志配置信息 @param string mode 当前应用运行模式 @return err error 返回错误信息

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL