log

package
v0.0.0-...-862ce61 Latest Latest
Warning

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

Go to latest
Published: Jan 1, 2022 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Debug

func Debug(pkg string, args ...interface{})

Debug is a debug level log message

func Debugf

func Debugf(pkg, format string, args ...interface{})

Debugf is a debug level formatted log message

func Error

func Error(err error, pkg string, args ...interface{})

Error is a error level error log message with optional annotation

func Errorf

func Errorf(err error, pkg, format string, args ...interface{})

Errorf is a error level formatted error log message with optional annotation

func Fatal

func Fatal(err error, pkg string, args ...interface{})

Fatal is a fatal level error log message with optional annotation that calls os.Exit(1)

func Fatalf

func Fatalf(err error, pkg, format string, args ...interface{})

Fatalf is a fatal level formatted error log message with optional annotation that calls os.Exit(1)

func Info

func Info(pkg string, args ...interface{})

Info is an info level log message

func Infof

func Infof(pkg, format string, args ...interface{})

Infof is an info level formatted log message

func Initialize

func Initialize(s string, c string)

Initialize sets up a logger with a specified service and coin that will be added to all logs

func Panic

func Panic(err error, pkg string, args ...interface{})

Panic is a panic level error log message with optional annotation that calls panic()

func Panicf

func Panicf(err error, pkg, format string, args ...interface{})

Panicf is a panic level formatted error log message with optional annotation that calls panic()

func SetCustomFields

func SetCustomFields(f Fields)

SetCustomFields will populate customFields to be added to the default log fields (thread safe writes)

func Warn

func Warn(err error, pkg string, args ...interface{})

Warn is a warn level error log message with optional annotation

func Warnf

func Warnf(err error, pkg, format string, args ...interface{})

Warnf is a warn level formatted error log message with optional annotation

Types

type Fields

type Fields map[string]interface{}

Fields is a map of annotations that can be added to a log message

Jump to

Keyboard shortcuts

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