logger

package
v0.0.0-...-15283aa Latest Latest
Warning

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

Go to latest
Published: Aug 11, 2024 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Debug

func Debug(msg string, args ...KV)

Debug logs a debug message

func DebugNs

func DebugNs(ns string, msg string, args ...KV)

DebugNs logs a debug message with a namespace It's for grouping logs consistently

func Error

func Error(msg string, args ...KV)

Error logs a error message

func ErrorNs

func ErrorNs(ns string, msg string, args ...KV)

ErrorNs logs a error message with a namespace It's for grouping logs consistently

func FatalError

func FatalError(msg string, args ...KV)

FatalError is equivalent to Error() followed by a call to os.Exit(1)

func FatalErrorNs

func FatalErrorNs(ns string, msg string, args ...KV)

FatalErrorNs is equivalent to FatalError() with a namespace

func Info

func Info(msg string, args ...KV)

Info logs a info message

func InfoNs

func InfoNs(ns string, msg string, args ...KV)

InfoNs logs a info message with a namespace It's for grouping logs consistently

func Warn

func Warn(msg string, args ...KV)

Warn logs a warn message

func WarnNs

func WarnNs(ns string, msg string, args ...KV)

WarnNs logs a warn message with a namespace It's for grouping logs consistently

Types

type KV

type KV map[string]any

KV is a record of key-value pair to be logged

Jump to

Keyboard shortcuts

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