From 9c8a4840945d07007e6d48666975236b485de815 Mon Sep 17 00:00:00 2001 From: meixiongfeng <766881921@qq.com> Date: Wed, 24 Aug 2022 09:36:04 +0800 Subject: [PATCH] =?UTF-8?q?=E6=97=A5=E5=BF=97=E8=BE=93=E5=87=BA=E6=AF=AB?= =?UTF-8?q?=E7=A7=92?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- modules/gateway/agent.go | 2 +- services/comp_gateroute.go | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/modules/gateway/agent.go b/modules/gateway/agent.go index e892e6813..5e0a555c1 100644 --- a/modules/gateway/agent.go +++ b/modules/gateway/agent.go @@ -276,7 +276,7 @@ func (this *Agent) messageDistribution(msg *pb.UserMessage) (err error) { return } } - this.gateway.Debugf("agent:%s uId:%s MessageDistribution t:%v reply:%v", this.sessionId, this.uId, time.Since(stime), reply) + this.gateway.Debugf("agent:%s uId:%s MessageDistribution t:%v reply:%v", this.sessionId, this.uId, time.Since(stime).Milliseconds(), reply) if reply.Code != pb.ErrorCode_Success { data, _ := anypb.New(&pb.NotifyErrorNotifyPush{ ReqMainType: msg.MainType, diff --git a/services/comp_gateroute.go b/services/comp_gateroute.go index 54cc89389..64dd36f40 100644 --- a/services/comp_gateroute.go +++ b/services/comp_gateroute.go @@ -157,7 +157,7 @@ func (this *SCompGateRoute) ReceiveMsg(ctx context.Context, args *pb.AgentMessag } // log.Errorf("[Handle Api] t:%v m:%s req:%v reply:%v", time.Since(stime), method, msg, reply) log.Error("[Handle Api]", - log.Field{Key: "t", Value: time.Since(stime)}, + log.Field{Key: "t", Value: time.Since(stime).Milliseconds()}, log.Field{Key: "m", Value: method}, log.Field{Key: "uid", Value: args.UserId}, log.Field{Key: "req", Value: msg}, @@ -168,7 +168,7 @@ func (this *SCompGateRoute) ReceiveMsg(ctx context.Context, args *pb.AgentMessag if this.options.Debug { // log.Debugf("[Handle Api] t:%v m:%s uid:%s req:%v reply:%v", time.Since(stime), method, args.UserId, msg, reply) log.Debug("[Handle Api]", - log.Field{Key: "t", Value: time.Since(stime)}, + log.Field{Key: "t", Value: time.Since(stime).Milliseconds()}, log.Field{Key: "m", Value: method}, log.Field{Key: "uid", Value: args.UserId}, log.Field{Key: "req", Value: msg},