Documentation
¶
Index ¶
Constants ¶
View Source
const ( //DEBUG is a constant of string type DEBUG = "DEBUG" //INFO is constant for info level log INFO = "INFO" //WARN is constant for warn level log WARN = "WARN" //ERROR is constant for error level log ERROR = "ERROR" //FATAL is constant for fail level log FATAL = "FATAL" )
Variables ¶
View Source
var Writers = make(map[string]io.Writer)
Writers is a map
Functions ¶
func NewLoggerExt ¶
NewLoggerExt is a function which is used to write new logs
func RegisterWriter ¶
RegisterWriter is used to register a io writer
Types ¶
type Config ¶
type Config struct {
LoggerLevel string `yaml:"loggerLevel"`
LoggerFile string `yaml:"loggerFile"`
Writers []string `yaml:"writers,flow"`
LogFormatText bool `yaml:"logFormatText"`
EnableRsyslog bool
RsyslogNetwork string
RsyslogAddr string
}
Config is a struct which stores details for maintaining logs
func DefaultConfig ¶
func DefaultConfig() *Config
DefaultConfig is a function which retuns config object with default configuration
Directories
¶
| Path | Synopsis |
|---|---|
|
examples
|
|
|
native
command
|
|
|
openlogging
command
|
|
|
Package rotate is the package for rotate
|
Package rotate is the package for rotate |
|
third_party
|
|
Click to show internal directories.
Click to hide internal directories.