diff --git a/modules/mgolog/core.go b/modules/dbservice/core.go similarity index 100% rename from modules/mgolog/core.go rename to modules/dbservice/core.go diff --git a/modules/mgolog/db_comp.go b/modules/dbservice/db_comp.go similarity index 100% rename from modules/mgolog/db_comp.go rename to modules/dbservice/db_comp.go diff --git a/modules/mgolog/module.go b/modules/dbservice/module.go similarity index 100% rename from modules/mgolog/module.go rename to modules/dbservice/module.go diff --git a/modules/modulebase.go b/modules/modulebase.go index 1694957f5..52b611ccc 100644 --- a/modules/modulebase.go +++ b/modules/modulebase.go @@ -253,17 +253,11 @@ func (this *ModuleBase) Warnf(format string, a ...interface{}) { } } func (this *ModuleBase) Errorf(format string, a ...interface{}) { - if this.options.GetDebug() { - this.options.GetLog().Errorf(fmt.Sprintf("[Module:%s] ", this.module.GetType())+format, a...) - } + this.options.GetLog().Errorf(fmt.Sprintf("[Module:%s] ", this.module.GetType())+format, a...) } func (this *ModuleBase) Panicf(format string, a ...interface{}) { - if this.options.GetDebug() { - this.options.GetLog().Panicf(fmt.Sprintf("[Module:%s] ", this.module.GetType())+format, a...) - } + this.options.GetLog().Panicf(fmt.Sprintf("[Module:%s] ", this.module.GetType())+format, a...) } func (this *ModuleBase) Fatalf(format string, a ...interface{}) { - if this.options.GetDebug() { - this.options.GetLog().Fatalf(fmt.Sprintf("[Module:%s] ", this.module.GetType())+format, a...) - } + this.options.GetLog().Fatalf(fmt.Sprintf("[Module:%s] ", this.module.GetType())+format, a...) } diff --git a/services/comp_gateroute.go b/services/comp_gateroute.go index cf49817d0..07c4df6f6 100644 --- a/services/comp_gateroute.go +++ b/services/comp_gateroute.go @@ -158,7 +158,7 @@ func (this *SCompGateRoute) ReceiveMsg(ctx context.Context, args *pb.AgentMessag } else { reply.Reply = session.Polls() if this.options.Debug { - log.Debugf("[Handle Api] consumetime:%v method:%s uid:%s msg:%v reply:%v", time.Since(stime), method, args.UserId, msg, reply) + log.Debugf("[Handle Api] consumetime:%v method:%s uid:%s msg:%v reply:%#v", time.Since(stime), method, args.UserId, msg, reply) } } } else { //未找到消息处理函数