Logger interface and tmLogger impl based on go-kit

This commit is contained in:
Anton Kaliaev
2017-04-27 13:42:03 +04:00
parent 706b9fbd67
commit ed76afd409
14 changed files with 473 additions and 68 deletions

18
log/nop_logger.go Normal file
View File

@ -0,0 +1,18 @@
package log
type nopLogger struct{}
// NewNopLogger returns a logger that doesn't do anything.
func NewNopLogger() Logger { return &nopLogger{} }
func (nopLogger) Info(string, ...interface{}) error {
return nil
}
func (nopLogger) Debug(string, ...interface{}) error {
return nil
}
func (nopLogger) Error(string, ...interface{}) error {
return nil
}