Documentation
¶
Index ¶
- func Critical(format string, values ...interface{})
- func Debug(format string, values ...interface{})
- func Fatalf(format string, values ...interface{})
- func Info(format string, values ...interface{})
- func Initialize()
- func IsDebug() bool
- func Notice(format string, values ...interface{})
- func RemovalRoutine()
- func SetLevel(lvl Level)
- func SetLogger(l Logger)
- func UseDatabaseLogger(db *sql.DB)
- func Warning(format string, values ...interface{})
- type BaseLogger
- type DatabaseLogger
- type Level
- type Logger
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Critical ¶
func Critical(format string, values ...interface{})
Critical prints error informations
func Fatalf ¶
func Fatalf(format string, values ...interface{})
Fatalf prints fatal informations, then os.Exit(1)
func Notice ¶
func Notice(format string, values ...interface{})
Notice prints information that should be seen
func RemovalRoutine ¶
func RemovalRoutine()
RemovalRoutine removes logs older than 1 day from database
func SetLogger ¶ added in v0.4.0
func SetLogger(l Logger)
SetLogger override private logger reference
func UseDatabaseLogger ¶
UseDatabaseLogger should be used only with proper database
Types ¶
type BaseLogger ¶
type BaseLogger struct {
}
BaseLogger logs on stdout
func (BaseLogger) Logf ¶
func (l BaseLogger) Logf(fmt string, values ...interface{})
Logf logs on stdout
type DatabaseLogger ¶
type DatabaseLogger struct {
// contains filtered or unexported fields
}
DatabaseLogger logs in database
func (DatabaseLogger) Logf ¶
func (l DatabaseLogger) Logf(format string, values ...interface{})
Logf insert log into "system_log" table
Click to show internal directories.
Click to hide internal directories.