zaplogger

package
v1.2.30 Latest Latest
Warning

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

Go to latest
Published: Apr 13, 2022 License: MIT Imports: 6 Imported by: 0

Documentation

Overview

实现文件 zaplogger 基于 zap 实现的logger

Index

Constants

This section is empty.

Variables

View Source
var (
	// Name log name
	Name = "ZapLogger"
)

Functions

This section is empty.

Types

type Option

type Option func(*Parm)

Option config wraps

func WithFileName

func WithFileName(filename string) Option

WithFileName 传入日志文件名

func WithLv

func WithLv(lv logger.Lvl) Option

WithLv 传入日志等级

func WithMaxAge

func WithMaxAge(age int) Option

WithMaxAge 文件最大保存天数

func WithMaxBackups

func WithMaxBackups(backups int) Option

WithMaxBackups 传入最大的日志备份数量

func WithMaxFileSize

func WithMaxFileSize(fileSize int) Option

WithMaxFileSize 传入单个日志文件最大的大小(M

type Parm

type Parm struct {
	// contains filtered or unexported fields
}

Parm nsq config

Jump to

Keyboard shortcuts

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