Documentation ¶
Index ¶
- func LogrusHandler(hook logrus.Hook) log.Handler
- func SetDSN(value string)
- func SetLevel(l string)
- func SetTestMode(t testing.TB)
- func TestHandler(t testing.TB, fmtr log.Format) log.Handler
- type Instance
- type Periodic
- func (l *Periodic) Debug(period time.Duration, msg string, ctx ...interface{})
- func (l *Periodic) Error(period time.Duration, msg string, ctx ...interface{})
- func (l *Periodic) Info(period time.Duration, msg string, ctx ...interface{})
- func (l *Periodic) Trace(period time.Duration, msg string, ctx ...interface{})
- func (l *Periodic) Warn(period time.Duration, msg string, ctx ...interface{})
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func LogrusHandler ¶
LogrusHandler converts logrus hook to log handler.
Types ¶
type Periodic ¶
type Periodic struct { Instance // contains filtered or unexported fields }
Periodic is the same as logger.Instance, but writes only once in a period
Click to show internal directories.
Click to hide internal directories.