Versions in this module Expand all Collapse all v1 v1.0.5 Sep 11, 2020 Changes in this version + const DefaultBufferedLines + const DefaultErrorLogLevel + const DefaultErrorLogPath + const DefaultLogLevel + const DefaultLogPath + func Debugf(ctx context.Context, fmt string, args ...interface{}) + func Errorf(ctx context.Context, fmt string, args ...interface{}) + func Fatalf(ctx context.Context, fmt string, args ...interface{}) + func Flush() error + func Infof(ctx context.Context, fmt string, args ...interface{}) + func Init(config *Config) + func Printf(ctx context.Context, fmt string, args ...interface{}) + func Rotate() error + func Tracef(ctx context.Context, fmt string, args ...interface{}) + func Warnf(ctx context.Context, fmt string, args ...interface{}) + func WithMoreInfo(ctx context.Context, info ...Info) context.Context + func WithTag(ctx context.Context, tag string) context.Context + type AsyncWriter struct + func NewAsyncWriter(writer io.WriteCloser, size int) *AsyncWriter + func (w *AsyncWriter) Close() error + func (w *AsyncWriter) Flush() error + func (w *AsyncWriter) Write(data []byte) (written int, err error) + type Config struct + BufferedLines int + ErrorLogLevel string + ErrorLogPath string + LogLevel string + LogPath string + PackagePrefix string + type Info struct + Key string + Value interface{} + type Level int + const LogDebug + const LogError + const LogFatal + const LogInfo + const LogTrace + const LogWarn + type Logger interface + Debugf func(ctx context.Context, fmt string, args ...interface{}) + Errorf func(ctx context.Context, fmt string, args ...interface{}) + Fatalf func(ctx context.Context, fmt string, args ...interface{}) + Infof func(ctx context.Context, fmt string, args ...interface{}) + Printf func(ctx context.Context, fmt string, args ...interface{}) + Tracef func(ctx context.Context, fmt string, args ...interface{}) + Warnf func(ctx context.Context, fmt string, args ...interface{})