mirror of
https://github.com/openimsdk/open-im-server.git
synced 2025-04-06 04:15:46 +08:00
Merge branch 'errcode' of github.com:OpenIMSDK/Open-IM-Server into errcode
# Conflicts: # pkg/common/mw/rpc_server_interceptor.go
This commit is contained in:
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…
x
Reference in New Issue
Block a user