cic-custodial/pkg/logg/asynq.go

34 lines
674 B
Go
Raw Permalink Normal View History

2022-11-30 10:51:24 +01:00
package logg
import "github.com/zerodha/logf"
type AsynqLogger struct {
Lo *logf.Logger
2022-11-30 10:51:24 +01:00
}
func AsynqCompatibleLogger(lo logf.Logger) AsynqLogger {
return AsynqLogger{
Lo: &lo,
2022-11-30 10:51:24 +01:00
}
}
func (l AsynqLogger) Debug(args ...interface{}) {
l.Lo.Debug("asynq: server", "msg", args[0])
2022-11-30 10:51:24 +01:00
}
func (l AsynqLogger) Info(args ...interface{}) {
l.Lo.Info("asynq: server", "msg", args[0])
2022-11-30 10:51:24 +01:00
}
func (l AsynqLogger) Warn(args ...interface{}) {
l.Lo.Warn("asynq: server", "msg", args[0])
2022-11-30 10:51:24 +01:00
}
func (l AsynqLogger) Error(args ...interface{}) {
l.Lo.Error("asynq: server", "msg", args[0])
2022-11-30 10:51:24 +01:00
}
func (l AsynqLogger) Fatal(args ...interface{}) {
l.Lo.Fatal("asynq: server", "msg", args[0])
2022-11-30 10:51:24 +01:00
}