logging

package
v1.5.0 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetNewConsoleWriter

func GetNewConsoleWriter() zerolog.ConsoleWriter

func Init

func Init(logLevel string, outputStream io.Writer) error

Types

type MultiLevelWriter

type MultiLevelWriter struct {
	io.Writer
	// contains filtered or unexported fields
}

func NewMultiLevelWriter

func NewMultiLevelWriter(isVerbose bool, consoleMinLevel zerolog.Level, consoleWriter, fileWriter io.Writer) MultiLevelWriter

func (*MultiLevelWriter) WriteLevel

func (mlw *MultiLevelWriter) WriteLevel(l zerolog.Level, p []byte) (int, error)

WriteLevel writes to all applicable writers, given the verbosity level and logging level if one writer returns an error, the writing stops and the error is returned the number of bytes written is the sum of bytes written to all writers

Jump to

Keyboard shortcuts

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