Categorygithub.com/alt-golang/logger
modulepackage
1.0.4
Repository: https://github.com/alt-golang/logger.git
Documentation: pkg.go.dev

# README

A simple configurable logging facade for Go, using the config package

Language Badge
release notes

Introduction

A simple configurable logging facade for Go, using the config package.

Usage

To use the module, import the module and call the GetLogger function with a logging category (your module url and package path is a sensible choice).

import  ( "github.com/alt-golang/logger") ;

Logger := logger.GetLogger("github.com/MyModule/mypackage");
Logger.Info('Hello world!');

The logger's DefaultFactory will create a ConsoleLogger (uses stdout and stderr) object instance, with the root logging level set to info by default. To change the logging level for your module (category), add something similar to the following in your config files.

local-development.json


  "logging" : {
     "format" : "json",
     "level" : {
       "/" : "info",
       "github.com/MyModule/mypackage" : "debug"
     }
  }
}

License

May be freely distributed under the MIT license.

Copyright (c) 2022 Craig Parravicini

# Functions

No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author

# Constants

No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author

# Structs

No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author

# Interfaces

No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author