logs

package
v1.2.0 Latest Latest
Warning

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

Go to latest
Published: Mar 20, 2022 License: MIT Imports: 8 Imported by: 0

Documentation

Overview

Package logs provides primitives to initialise and access the logger.

Index

Constants

This section is empty.

Variables

View Source
var (
	Logger *log.Logger
)

Logger instance to be used for logging purposes

Functions

func Init

func Init() error

Init initialises the log file and the different loggers: WarningLogger, InfoLogger and ErrorLogger.

func SetLogLevel added in v1.2.0

func SetLogLevel(logLevel string) error

SetLogLevel sets the log level for global Logger by taking in the string representation of a log.Level

Types

type LominusFormatter added in v1.2.0

type LominusFormatter struct {
	log.TextFormatter
}

LominusFormatter provides the format for log outputs

func (*LominusFormatter) Format added in v1.2.0

func (f *LominusFormatter) Format(entry *log.Entry) ([]byte, error)

Format returns the formatted log string

Jump to

Keyboard shortcuts

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