log

package
v0.65.1 Latest Latest
Warning

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

Go to latest
Published: May 5, 2023 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Overview

nolint

Index

Constants

View Source
const (
	LevelAll   = "all"
	LevelDebug = "debug"
	LevelInfo  = "info"
	LevelWarn  = "warn"
	LevelError = "error"
	LevelNone  = "none"
)
View Source
const (
	FormatLogFmt = "logfmt"
	FormatJSON   = "json"
)

Variables

View Source
var AvailableLogFormats = []string{
	FormatLogFmt,
	FormatJSON,
}

AvailableLogFormats is a list of supported log formats

AvailableLogLevels is a list of supported logging levels

Functions

func NewLogger

func NewLogger(level string, format string) (log.Logger, error)

NewLogger returns a log.Logger that prints in the provided format at the provided level with a UTC timestamp and the caller of the log entry.

Types

This section is empty.

Jump to

Keyboard shortcuts

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