move log package to /infra (#17023)

ref #14679

Signed-off-by: zhulongcheng <zhulongcheng.me@gmail.com>
This commit is contained in:
zhulongcheng
2019-05-13 08:45:54 +02:00
committed by Carl Bergquist
parent 0efb8821f9
commit 2fff8f77dc
127 changed files with 118 additions and 118 deletions
+31
View File
@@ -0,0 +1,31 @@
package log
import "github.com/inconshreveable/log15"
type Lvl int
const (
LvlCrit Lvl = iota
LvlError
LvlWarn
LvlInfo
LvlDebug
)
type Logger interface {
// New returns a new Logger that has this logger's context plus the given context
New(ctx ...interface{}) log15.Logger
// GetHandler gets the handler associated with the logger.
GetHandler() log15.Handler
// SetHandler updates the logger to write records to the specified handler.
SetHandler(h log15.Handler)
// Log a message at the given level with context key/value pairs
Debug(msg string, ctx ...interface{})
Info(msg string, ctx ...interface{})
Warn(msg string, ctx ...interface{})
Error(msg string, ctx ...interface{})
Crit(msg string, ctx ...interface{})
}