micro/debug/log/noop/noop.go

24 lines
352 B
Go
Raw Normal View History

2019-12-18 19:12:25 +03:00
package noop
import (
"github.com/micro/go-micro/debug/log"
)
type noop struct{}
func (n *noop) Read(...log.ReadOption) ([]log.Record, error) {
return nil, nil
}
func (n *noop) Write(log.Record) error {
return nil
}
func (n *noop) Stream() (log.Stream, error) {
return nil, nil
}
func NewLog(opts ...log.Option) log.Log {
return new(noop)
}