logger

package
v1.7.6 Latest Latest
Warning

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

Go to latest
Published: Jun 29, 2022 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var CliLogFilePathOverride string
View Source
var ConsoleLogLevelOverride string
View Source
var Debug = noOp
View Source
var DisableLogFile bool
View Source
var Err = noOp
View Source
var ErrCreateLogFileFailed = errors.New("create log file failed")
View Source
var ErrLogFileDisabled = errors.New("logfile disabled")
View Source
var Info = noOp
View Source
var NetworkLog bool
View Source
var NetworkLogger *zap.SugaredLogger
View Source
var Warn = noOp

Functions

func CreateLogFile added in v1.6.3

func CreateLogFile() (*os.File, error)

func InitLogger

func InitLogger() error

func LogFileCleanup

func LogFileCleanup()

LogFileCleanup auto remove log files which created between staticRefTime and 7 days ago

Types

type LogErr added in v1.6.3

type LogErr struct {
	Key   error
	Cause error
}

func (*LogErr) Error added in v1.6.3

func (e *LogErr) Error() string

func (*LogErr) Is added in v1.6.3

func (e *LogErr) Is(target error) bool

func (*LogErr) String added in v1.6.3

func (e *LogErr) String() string

func (*LogErr) Unwrap added in v1.6.3

func (e *LogErr) Unwrap() error

type WrappedLogger

type WrappedLogger struct {
	*zap.Logger
	// contains filtered or unexported fields
}

func (*WrappedLogger) Printf

func (this *WrappedLogger) Printf(format string, a ...interface{})

func (*WrappedLogger) Println

func (this *WrappedLogger) Println(args ...interface{})

Jump to

Keyboard shortcuts

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