Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // LogLevelFnMap is a map between loglevel and log functions from logrus LogLevelFnMap = func(ctx context.Context, lev logrus.Level) func(args ...interface{}) { lm := map[logrus.Level]func(args ...interface{}){ logrus.TraceLevel: logrus.WithContext(ctx).Trace, logrus.DebugLevel: logrus.WithContext(ctx).Debug, logrus.InfoLevel: logrus.WithContext(ctx).Info, logrus.WarnLevel: logrus.WithContext(ctx).Warn, logrus.ErrorLevel: logrus.WithContext(ctx).Error, } return lm[lev] } )
Functions ¶
This section is empty.
Types ¶
type MyFormatter ¶
type MyFormatter struct { logrus.TextFormatter // contains filtered or unexported fields }
MyFormatter ...
func GetDefaultFormatter ¶
func GetDefaultFormatter() *MyFormatter
GetDefaultFormatter returns the default formatter used by all Safescale modules
Click to show internal directories.
Click to hide internal directories.