Closed brounnoupegreula-7757 closed 3 weeks ago
hi i try the example logger, and user uber zap as my custom logger
package logger
import ( "go.uber.org/zap" )
type RabbitMqZapLogger struct { Logger *zap.Logger } func (l RabbitMqZapLogger) Fatalf(format string, v ...interface{}) { l.Logger.Sugar().Fatalf(format, v...) } func (l RabbitMqZapLogger) Errorf(format string, v ...interface{}) { l.Logger.Sugar().Errorf(format, v...) } func (l RabbitMqZapLogger) Warnf(format string, v ...interface{}) { l.Logger.Sugar().Warnf(format, v...) } func (l RabbitMqZapLogger) Infof(format string, v ...interface{}) { l.Logger.Sugar().Infof(format, v...) } func (l RabbitMqZapLogger) Debugf(format string, v ...interface{}) { l.Logger.Sugar().Debugf(format, v...) }
but after the app shutdown or interupt by user, look like the connection manager (close function) lost zap formating, any idea why like this?
Hello, Use WithConnectionOptionsLogger connection option?
i fix this @thibleroy
WithConnectionOptionsLogger worked :)
thank you
hi i try the example logger, and user uber zap as my custom logger
package logger
import ( "go.uber.org/zap" )
but after the app shutdown or interupt by user, look like the connection manager (close function) lost zap formating, any idea why like this?