Documentation ¶
Index ¶
- Constants
- func Debug(args ...interface{})
- func Debugf(format string, args ...interface{})
- func Error(args ...interface{})
- func Errorf(format string, args ...interface{})
- func Fatal(args ...interface{})
- func Fatalf(format string, args ...interface{})
- func GinLogger() gin.HandlerFunc
- func Info(args ...interface{})
- func Infof(format string, args ...interface{})
- func SetDebug(d bool)
- func Warn(args ...interface{})
- func Warnf(format string, args ...interface{})
- func WithField(key string, value interface{}) *logrus.Entry
- func WithFields(fs logrus.Fields) *logrus.Entry
- type MicroLoggerI
- type NsqLoggerI
- type OrmLoggerI
Constants ¶
View Source
const ( TraceIDKey = "trace_id" UserIDKey = "user_id" VersionKey = "version" ServiceNameKey = "service_name" )
定义键名
Variables ¶
This section is empty.
Functions ¶
func GinLogger ¶
func GinLogger() gin.HandlerFunc
Types ¶
type MicroLoggerI ¶
type MicroLoggerI struct{}
func NewMicroLogger ¶
func NewMicroLogger() *MicroLoggerI
func (*MicroLoggerI) Log ¶
func (o *MicroLoggerI) Log(v ...interface{})
func (*MicroLoggerI) Logf ¶
func (o *MicroLoggerI) Logf(format string, v ...interface{})
Logf logs formatted using the default logger
type OrmLoggerI ¶
type OrmLoggerI struct { }
func NewGormLogger ¶
func NewGormLogger() *OrmLoggerI
func (*OrmLoggerI) Print ¶
func (o *OrmLoggerI) Print(v ...interface{})
Click to show internal directories.
Click to hide internal directories.