logger

package
v0.0.0-...-5c79d48 Latest Latest
Warning

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

Go to latest
Published: Feb 15, 2024 License: AGPL-3.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Get

func Get(ctx context.Context) log.FieldLogger

func Init

func Init()

InitLogger sets up logger for a typical daemon scenario until configuration file is parsed

func SetField

func SetField(ctx context.Context, key string, value interface{}) context.Context

func SetFields

func SetFields(ctx context.Context, logFields Fields) context.Context

func Setup

func Setup(conf Config) error

func Standard

func Standard() log.FieldLogger

func WithField

func WithField(ctx context.Context, key string, value interface{}) (context.Context, log.FieldLogger)

func WithFields

func WithFields(ctx context.Context, logFields Fields) (context.Context, log.FieldLogger)

func WithLogger

func WithLogger(ctx context.Context, logger log.FieldLogger) context.Context

Types

type Config

type Config struct {
	Output   string `toml:"output"`
	Severity string `toml:"severity"`
}

type Fields

type Fields = log.Fields

Jump to

Keyboard shortcuts

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