logs

package module
v0.0.0-...-f29a084 Latest Latest
Warning

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

Go to latest
Published: Feb 5, 2022 License: MIT Imports: 4 Imported by: 4

README

logs

Documentation

Index

Constants

View Source
const (
	DefaultConfig = `` /* 1154-byte string literal not displayed */

)

Variables

This section is empty.

Functions

func Critical

func Critical(format string, params ...interface{})

func CtxCritical

func CtxCritical(ctx context.Context, format string, params ...interface{})

func CtxDebug

func CtxDebug(ctx context.Context, format string, params ...interface{})

func CtxError

func CtxError(ctx context.Context, format string, params ...interface{})

func CtxInfo

func CtxInfo(ctx context.Context, format string, params ...interface{})

func CtxTrace

func CtxTrace(ctx context.Context, format string, params ...interface{})

func CtxWarn

func CtxWarn(ctx context.Context, format string, params ...interface{})

func CtxWithLogId

func CtxWithLogId(ctx context.Context, logId string) context.Context

func Debug

func Debug(format string, params ...interface{})

func Error

func Error(format string, params ...interface{})

func Flush

func Flush()

func GenLogId

func GenLogId() string

func GetLogId

func GetLogId(ctx context.Context) string

func Info

func Info(format string, params ...interface{})

func InitFromConfigAsFile

func InitFromConfigAsFile(filePath string)

func InitFromConfigAsString

func InitFromConfigAsString(conf string)

func NewCtxWithLogId

func NewCtxWithLogId() context.Context

func Trace

func Trace(format string, params ...interface{})

func Warn

func Warn(format string, params ...interface{})

Types

type ContextKey

type ContextKey string
const LogIdContextKey ContextKey = "X_LOG_ID"

Jump to

Keyboard shortcuts

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