cic-custodial/pkg/logg/asynq.go
Mohammed Sohail cf1f9f34c3
refactor: task handlers, emitter, tx signer, et.c.
* fallback to custom ethereum checksum validator -> https://github.com/go-playground/validator/issues/1073
* decouple jetsream emitter to separate package
* refactor task handlers into individual files
* add error handler for echo to capture unexpected errors and log them
* move handler dependencies into single struct container -> custodialContainer
* replace signer to use EIP 1559 signer -> celoutils v1
* Add 1 minutes timeout to all custodial tasks
2023-02-20 09:56:30 +00:00

34 lines
642 B
Go

package logg
import "github.com/zerodha/logf"
type AsynqLogger struct {
Lo *logf.Logger
}
func AsynqCompatibleLogger(lo logf.Logger) AsynqLogger {
return AsynqLogger{
Lo: &lo,
}
}
func (l AsynqLogger) Debug(args ...interface{}) {
l.Lo.Debug("asynq", "debug", args[0])
}
func (l AsynqLogger) Info(args ...interface{}) {
l.Lo.Info("asynq", "info", args[0])
}
func (l AsynqLogger) Warn(args ...interface{}) {
l.Lo.Warn("asynq", "warn", args[0])
}
func (l AsynqLogger) Error(args ...interface{}) {
l.Lo.Error("asynq", "error", args[0])
}
func (l AsynqLogger) Fatal(args ...interface{}) {
l.Lo.Fatal("asynq", "fatal", args[0])
}