log

package
v0.6.0 Latest Latest
Warning

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

Go to latest
Published: Dec 4, 2023 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New added in v0.3.0

func New() *zap.SugaredLogger

New delegated to NewAzLevel and returns a sugared zap Logger configured for the default level which is either determined by the environment variable LOG_LEVEL, or defaults to 'info'

func NewAtLevel

func NewAtLevel(levelStr string) *zap.SugaredLogger

NewAtLevel returns a sugared zap Logger configured for the given level if the string is empty or cannot be parsed, default level INFO is used allowed levels: "DEBUG","INFO","WARN","ERROR,"PANIC","DPANIC","FATAL"

func SyncSilently added in v0.5.0

func SyncSilently(l *zap.SugaredLogger)

SyncSilently make sure any buffered log entries are flushed when Produce returns use with defer at the beginning of your method as follows:

defer log.SyncSilently(&c.logger)

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL
JackTT - Gopher 🇻🇳