fix
This commit is contained in:
parent
c80cb7bc9b
commit
e800b18325
|
@ -273,16 +273,16 @@ func sendToOutChanByUserIndex(userId, guestId int64, message []byte) {
|
|||
}
|
||||
|
||||
// 消费用户索引创建/删除/发送消息中的任务数据
|
||||
func ConsumeUserPoolData(ctx context.Context) {
|
||||
func ConsumeUserConnPoolCtlChanData(ctx context.Context) {
|
||||
defer func() {
|
||||
if err := recover(); err != nil {
|
||||
logx.Error("consumeUserPoolData panic:", err)
|
||||
logx.Error("ConsumeUserConnPoolCtlChanData panic:", err)
|
||||
}
|
||||
}()
|
||||
go func() {
|
||||
select {
|
||||
case <-ctx.Done():
|
||||
panic("ConsumeUserPoolData ctx deadline")
|
||||
panic("ConsumeUserConnPoolCtlChanData ctx deadline")
|
||||
}
|
||||
}()
|
||||
for {
|
||||
|
|
|
@ -36,7 +36,7 @@ func main() {
|
|||
//消费公共通知队列的数据
|
||||
go logic.ConsumeCommonCacheData(ctx1)
|
||||
//消费用户索引创建/删除/发送消息中的任务数据
|
||||
go logic.ConsumeUserPoolData(ctx1)
|
||||
go logic.ConsumeUserConnPoolCtlChanData(ctx1)
|
||||
fmt.Printf("Starting server at %s:%d...\n", c.Host, c.Port)
|
||||
server.Start()
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user