zaplog

package
v0.0.0-...-acf58c8 Latest Latest
Warning

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

Go to latest
Published: Mar 4, 2021 License: Apache-2.0 Imports: 9 Imported by: 3

Documentation

Index

Constants

View Source
const (
	DEBUG            = zapcore.DebugLevel
	INFO             = zapcore.InfoLevel
	WARN             = zapcore.WarnLevel
	ErrNoStoragePath = "error: logger is configured without a storage path"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type ZapLogger

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

ZapLogger implements Logger interface as defined in "go.amplifyedge.org/sys-share-v2/sys-core/service/logging"

func NewZapLogger

func NewZapLogger(level zapcore.Level, moduleName string, isDevelopmentMode bool, storagePath string) *ZapLogger

Zap Logger constructor

func (*ZapLogger) Debug

func (l *ZapLogger) Debug(args ...interface{})

func (*ZapLogger) Debugf

func (l *ZapLogger) Debugf(template string, args ...interface{})

func (*ZapLogger) Error

func (l *ZapLogger) Error(args ...interface{})

func (*ZapLogger) Errorf

func (l *ZapLogger) Errorf(template string, args ...interface{})

func (*ZapLogger) Fatal

func (l *ZapLogger) Fatal(args ...interface{})

func (*ZapLogger) Fatalf

func (l *ZapLogger) Fatalf(template string, args ...interface{})

func (*ZapLogger) GetLogPath

func (l *ZapLogger) GetLogPath() (string, error)

func (*ZapLogger) GetServerStreamInterceptor

func (l *ZapLogger) GetServerStreamInterceptor() grpc.StreamServerInterceptor

func (*ZapLogger) GetServerUnaryInterceptor

func (l *ZapLogger) GetServerUnaryInterceptor() grpc.UnaryServerInterceptor

func (*ZapLogger) Info

func (l *ZapLogger) Info(args ...interface{})

func (*ZapLogger) Infof

func (l *ZapLogger) Infof(template string, args ...interface{})

func (*ZapLogger) InitLogger

func (l *ZapLogger) InitLogger(extraFields map[string]interface{})

Init logger

func (*ZapLogger) Panic

func (l *ZapLogger) Panic(args ...interface{})

func (*ZapLogger) Panicf

func (l *ZapLogger) Panicf(template string, args ...interface{})

func (*ZapLogger) Warn

func (l *ZapLogger) Warn(args ...interface{})

func (*ZapLogger) Warnf

func (l *ZapLogger) Warnf(template string, args ...interface{})

func (*ZapLogger) WithFields

func (l *ZapLogger) WithFields(args map[string]interface{}) logging.Logger

ZapLogger methods to satisfy Logger interface

Jump to

Keyboard shortcuts

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