zap

package
v0.3.6 Latest Latest
Warning

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

Go to latest
Published: Jul 28, 2023 License: Apache-2.0 Imports: 10 Imported by: 3

Documentation

Index

Constants

View Source
const (
	LOG_FILENAME          = "LOG_FILENAME"
	LOG_STORAGE_DIRECTORY = "LOG_STORAGE_DIRECTORY"
	LOG_STORAGE_POLICY    = "LOG_STORAGE_POLICY"
	LOG_MAX_SIZE          = "LOG_MAX_SIZE"
	LOG_MAX_BACKUPS       = "LOG_MAX_BACKUPS"
	LOG_MAX_AGE           = "LOG_MAX_AGE"
	LOG_COMPRESS          = "LOG_COMPRESS"
)

Environment variable key

Variables

This section is empty.

Functions

func GetEncoder

func GetEncoder() zapcore.Encoder

func New

func New() logr.Logger

func NewCore

func NewCore() []zapcore.Core

func NewZapLogger

func NewZapLogger() *zap.Logger

Types

type Logger

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

func NewLogger

func NewLogger() *Logger

NewLogger this func is special adaptation kratos log interface

func (*Logger) Close

func (l *Logger) Close() error

func (*Logger) Log

func (l *Logger) Log(level log.Level, keyvals ...interface{}) error

func (*Logger) Sync

func (l *Logger) Sync() error

Jump to

Keyboard shortcuts

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