logger

package
v0.0.0-...-a2c6c8b Latest Latest
Warning

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

Go to latest
Published: Apr 13, 2020 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Overview

Package logger ...

This package implements the logger which helps us to view the application logs Application logs can be redirected to a standard ouptut or to a log file This package supports three levels of logging DEBUG,INFO,ERROR Debug logs will be written only if debugEnabled is set in config This will not perform any error handling it just adds the useful information in the logs

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Logger

type Logger interface {
	Error(msg string, ctx map[string]interface{})
	Info(msg string, ctx map[string]interface{})
	Debug(msg string, ctx map[string]interface{})
}

The Logger type is the skeleton and provided the base methods to be implemented

func New

func New(w io.Writer, isDebug bool) Logger

New function creates the basic logger will be part of application type

Jump to

Keyboard shortcuts

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