Help us shape the future of Go! Take the 2026 Go Developer Survey

internal

package
v0.13.0 Latest Latest
Warning

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

Go to latest
Published: Nov 12, 2025 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Logger = logger.Logger
View Source
var PythonPriorityMap = PriorityMap{
	"CRITICAL": PriCrit,
	"ERROR":    PriErr,
	"WARNING":  PriWarning,
	"INFO":     PriInfo,
	"DEBUG":    PriDebug,
}

PythonPriorityMap maps Python logging levels to syslog severity levels. https://docs.Python.org/3/library/logging.html#levels

View Source
var ZerologPriorityMap = PriorityMap{
	zerolog.LevelTraceValue: PriDebug,
	zerolog.LevelDebugValue: PriDebug,
	zerolog.LevelInfoValue:  PriInfo,
	zerolog.LevelWarnValue:  PriWarning,
	zerolog.LevelErrorValue: PriErr,
	zerolog.LevelFatalValue: PriCrit,
	zerolog.LevelPanicValue: PriCrit,
}

ZerologPriorityMap maps zerolog logging levels to syslog severity levels. https://pkg.go.dev/github.com/rs/zerolog#pkg-variables

Functions

func OmitPairs

func OmitPairs(kk ...string) func(iter.Seq2[string, any]) iter.Seq2[string, any]

OmitPairs returns a function which removes all kk from seq.

func SortedPairs

func SortedPairs(e Event) iter.Seq2[string, any]

SortedPairs iterates over e.Message().Fields(), yields the field "message" or "msg" first, and everything else sorted lexically by name afterwards.

Types

type PriorityMap

type PriorityMap map[any]Priority

func (PriorityMap) Get

func (m PriorityMap) Get(v any) Priority

Jump to

Keyboard shortcuts

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