log

package
v0.0.0-...-6ee8545 Latest Latest
Warning

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

Go to latest
Published: Feb 7, 2023 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Debug

func Debug(keyvals ...interface{})

Debug logs a DEBUG level message, ignoring logging errors

func Error

func Error(keyvals ...interface{})

Error logs an ERROR level message, ignoring logging errors

func Fatal

func Fatal(keyvals ...interface{})

Fatal logs an ERROR level message and exits

func GetLogger

func GetLogger() log.Logger

func Info

func Info(keyvals ...interface{})

Info logs an INFO level message, ignoring logging errors

func Init

func Init(cfg Config) error

Init starts logging given the configuration. By default, it uses logfmt format and minimum logging level.

func Warn

func Warn(keyvals ...interface{})

Warn logs a WARN level message, ignoring logging errors

Types

type Config

type Config struct {
	Level  string
	Format string
}

Config represents a logger configuration used upon initialization.

Jump to

Keyboard shortcuts

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