Documentation ¶
Index ¶
- Constants
- func IsErrLog(p []byte) bool
- func Log() *logrus.Logger
- type Entry
- type GormLogger
- func (l *GormLogger) Error(ctx context.Context, s string, args ...interface{})
- func (l *GormLogger) Info(ctx context.Context, s string, args ...interface{})
- func (l *GormLogger) LogMode(glog.LogLevel) glog.Interface
- func (l *GormLogger) Trace(ctx context.Context, begin time.Time, fc func() (string, int64), err error)
- func (l *GormLogger) Warn(ctx context.Context, s string, args ...interface{})
- type Writer
Constants ¶
View Source
const AuditEventField = "audit_event"
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Entry ¶ added in v0.18.0
func WithContext ¶
func (*Entry) EWithFields ¶ added in v0.30.0
func (*Entry) PushWithAuditEvent ¶ added in v0.23.0
func (e *Entry) PushWithAuditEvent(event *audit.BasicEvent)
func (*Entry) WithAuditEvent ¶ added in v0.18.0
func (e *Entry) WithAuditEvent(event *audit.BasicEvent) *Entry
type GormLogger ¶ added in v0.16.0
type GormLogger struct { Logger *logrus.Logger SlowThreshold time.Duration SkipErrRecordNotFound bool }
Inspired by: https://github.com/onrik/gorm-logrus/logger.go MIT License: https://github.com/onrik/gorm-logrus/LICENSE
func NewGormLogger ¶ added in v0.16.0
func (*GormLogger) Error ¶ added in v0.16.0
func (l *GormLogger) Error(ctx context.Context, s string, args ...interface{})
func (*GormLogger) Info ¶ added in v0.16.0
func (l *GormLogger) Info(ctx context.Context, s string, args ...interface{})
func (*GormLogger) LogMode ¶ added in v0.16.0
func (l *GormLogger) LogMode(glog.LogLevel) glog.Interface
Click to show internal directories.
Click to hide internal directories.