This commit is contained in:
wh_zcy 2023-03-29 19:24:17 +08:00
parent cf33b5b139
commit 7253886ac5
2 changed files with 5 additions and 3 deletions

View File

@ -321,8 +321,7 @@ func (this *Agent) messageDistribution(msg *pb.UserMessage) (err error) {
}
stime := time.Now()
// this.gateway.Debugf("----------3 agent:%s uId:%s MainType:%s SubType:%s ", this.sessionId, this.uId, msg.MainType, msg.SubType)
// ctx, _ := context.WithTimeout(context.Background(), time.Second*5)
ctx := context.Background()
ctx, _ := context.WithTimeout(context.Background(), time.Second*5)
if len(serviceTag) == 0 {
// this.gateway.Debugf("----------4 agent:%s uId:%s MainType:%s SubType:%s ", this.sessionId, this.uId, msg.MainType, msg.SubType)
if err = this.gateway.Service().RpcCall(ctx, servicePath, string(comm.Rpc_GatewayRoute), req, reply); err != nil {

View File

@ -8,6 +8,7 @@ import (
"go_dreamfactory/modules"
"go_dreamfactory/pb"
cfg "go_dreamfactory/sys/configure/structs"
"go_dreamfactory/utils"
)
var _ comm.IWorldtask = (*Worldtask)(nil)
@ -89,7 +90,9 @@ func (this *Worldtask) TaskCondFinishNotify(session comm.IUserSession, condId in
wt = &pb.Worldtask{}
}
wt.CondiIds = append(wt.CondiIds, condId)
if _, ok := utils.Findx(wt.CondiIds, condId); !ok {
wt.CondiIds = append(wt.CondiIds, condId)
}
userTask.CurrentTask[groupId] = wt