zap

package
v0.54.1 Latest Latest
Warning

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

Go to latest
Published: Jun 18, 2021 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Logger

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

Logger represents a zap logger implementation.

func NewLogger

func NewLogger(outputPath string) *Logger

NewLogger creates an initialized zap logger instance.

func (*Logger) Debugf

func (l *Logger) Debugf(msg string, args ...interface{})

Debugf uses fmt.Sprintf to log a `debug` templated message.

func (*Logger) Debugw

func (l *Logger) Debugw(msg string, keysAndValues ...interface{})

Debugw writes a 'debug' message to configured logger with some additional context.

func (*Logger) Errorf

func (l *Logger) Errorf(msg string, args ...interface{})

Errorf uses fmt.Sprintf to log an `error` templated message.

func (*Logger) Errorw

func (l *Logger) Errorw(msg string, keysAndValues ...interface{})

Errorw writes an 'error' message to configured logger with some additional context.

func (*Logger) Fatalf

func (l *Logger) Fatalf(msg string, args ...interface{})

Fatalf uses fmt.Sprintf to log a `fatal` templated message.

func (*Logger) Fatalw

func (l *Logger) Fatalw(msg string, keysAndValues ...interface{})

Fatalw writes a 'fatal' message to configured logger with some additional context.

func (*Logger) Infof

func (l *Logger) Infof(msg string, args ...interface{})

Infof uses fmt.Sprintf to log an `info` templated message.

func (*Logger) Infow

func (l *Logger) Infow(msg string, keysAndValues ...interface{})

Infow writes a 'info' message to configured logger with some additional context.

func (*Logger) Warnf

func (l *Logger) Warnf(msg string, args ...interface{})

Warnf uses fmt.Sprintf to log a `warn` templated message.

func (*Logger) Warnw

func (l *Logger) Warnw(msg string, keysAndValues ...interface{})

Warnw writes a 'warning' message to configured logger with some additional context.

Jump to

Keyboard shortcuts

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