logger

package
v2.0.22 Latest Latest
Warning

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

Go to latest
Published: May 2, 2024 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const Disabled = "disabled"
View Source
const LevelDebug = "debug"
View Source
const LevelError = "error"
View Source
const LevelFatal = "fatal"
View Source
const LevelInfo = "info"
View Source
const LevelWarn = "warn"

Variables

View Source
var NOOP = noopLogger{}

Functions

This section is empty.

Types

type JSONLogger

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

func NewJSONLogger

func NewJSONLogger(level string) *JSONLogger

func (*JSONLogger) Debug

func (l *JSONLogger) Debug(message string, kvs ...map[string]interface{})

func (*JSONLogger) Error

func (l *JSONLogger) Error(message string, err error, kvs ...map[string]interface{})

func (*JSONLogger) Fatal

func (l *JSONLogger) Fatal(message string, err error, kvs ...map[string]interface{})

func (*JSONLogger) Info

func (l *JSONLogger) Info(message string, kvs ...map[string]interface{})

func (*JSONLogger) Warn

func (l *JSONLogger) Warn(message string, kvs ...map[string]interface{})

type TextLogger added in v2.0.17

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

func NewLogger

func NewLogger(level string, opts ...func(w *zerolog.ConsoleWriter)) *TextLogger

func (*TextLogger) Debug added in v2.0.17

func (h *TextLogger) Debug(message string, kvs ...map[string]interface{})

func (*TextLogger) Error added in v2.0.17

func (h *TextLogger) Error(message string, err error, kvs ...map[string]interface{})

func (*TextLogger) Fatal added in v2.0.17

func (h *TextLogger) Fatal(message string, err error, kvs ...map[string]interface{})

func (*TextLogger) Info added in v2.0.17

func (h *TextLogger) Info(message string, kvs ...map[string]interface{})

func (*TextLogger) Warn added in v2.0.17

func (h *TextLogger) Warn(message string, kvs ...map[string]interface{})

Jump to

Keyboard shortcuts

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