model

package
v0.3.1 Latest Latest
Warning

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

Go to latest
Published: Feb 16, 2022 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ConvertLevel

func ConvertLevel(level zerolog.Level) string

ConvertLevel Convert a zerolog log level into the corresponding pino one

func ParseLevel

func ParseLevel(level string) (zerolog.Level, error)

ParseLevel Parse a string name of the log level and return the corresponding zerolog level

Types

type PinoLevel

type PinoLevel string

PinoLevel is a string representation of levels adopted PinoJS logger

const (
	Trace PinoLevel = "10"
	Debug PinoLevel = "20"
	Info  PinoLevel = "30"
	Warn  PinoLevel = "40"
	Error PinoLevel = "50"
	Fatal PinoLevel = "60"
	Panic PinoLevel = "70"
)

Represents all the Pino log levels accepted Note: the Panic level has been added to cover this log level not available in Javascript

Jump to

Keyboard shortcuts

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