Merge branch 'errcode' of github.com:OpenIMSDK/Open-IM-Server into errcode

# Conflicts:
#	pkg/common/mw/rpc_server_interceptor.go
test-errcode
wangchuxiao 2 years ago
parent fcbcfbb17c
commit 6de048d84f

@ -47,10 +47,6 @@ func ZError(ctx context.Context, msg string, err error, keysAndValues ...interfa
type ZapLogger struct {
zap *zap.SugaredLogger
// store original logger without sampling to avoid multiple samplers
SampleDuration time.Duration
SampleInitial int
SampleInterval int
}
func NewZapLogger() (*ZapLogger, error) {
@ -61,10 +57,10 @@ func NewZapLogger() (*ZapLogger, error) {
DisableStacktrace: true,
InitialFields: map[string]interface{}{"PID": os.Getegid()},
}
zl := &ZapLogger{}
if config.Config.Log.Stderr {
zapConfig.OutputPaths = append(zapConfig.OutputPaths, "stderr")
}
zl := &ZapLogger{}
opts, err := zl.cores()
if err != nil {
return nil, err

Loading…
Cancel
Save