mirror of
https://github.com/openimsdk/open-im-server.git
synced 2025-08-09 20:49:52 +08:00
batch push
This commit is contained in:
parent
da0e73fe11
commit
0e77caa329
@ -206,6 +206,7 @@ func (r *RPCServer) OnlineBatchPushOneMsg(_ context.Context, req *pbRelay.Online
|
|||||||
platformList = append(platformList, k)
|
platformList = append(platformList, k)
|
||||||
}
|
}
|
||||||
needPushMapList := r.GetSingleUserMsgForPushPlatforms(req.OperationID, req.MsgData, v, platformList)
|
needPushMapList := r.GetSingleUserMsgForPushPlatforms(req.OperationID, req.MsgData, v, platformList)
|
||||||
|
log.Debug(req.OperationID, "GetSingleUserMsgForPushPlatforms ", req.MsgData.Seq, v, platformList, len(needPushMapList))
|
||||||
for platform, list := range needPushMapList {
|
for platform, list := range needPushMapList {
|
||||||
if list != nil {
|
if list != nil {
|
||||||
for _, v := range list {
|
for _, v := range list {
|
||||||
@ -218,7 +219,7 @@ func (r *RPCServer) OnlineBatchPushOneMsg(_ context.Context, req *pbRelay.Online
|
|||||||
resultCode := sendMsgBatchToUser(userConnMap[platform], replyBytes.Bytes(), req, platform, v)
|
resultCode := sendMsgBatchToUser(userConnMap[platform], replyBytes.Bytes(), req, platform, v)
|
||||||
if resultCode == 0 && utils.IsContainInt(platform, r.pushTerminal) {
|
if resultCode == 0 && utils.IsContainInt(platform, r.pushTerminal) {
|
||||||
tempT.OnlinePush = true
|
tempT.OnlinePush = true
|
||||||
log.Info(req.OperationID, "PushSuperMsgToUser is success By Ws", "args", req.String(), "recvPlatForm", constant.PlatformIDToName(platform), "recvID", v)
|
log.Info(req.OperationID, "PushSuperMsgToUser is success By Ws", "args", req.String(), "recv PlatForm", constant.PlatformIDToName(platform), "recvID", v)
|
||||||
temp := &pbRelay.SingleMsgToUserPlatform{
|
temp := &pbRelay.SingleMsgToUserPlatform{
|
||||||
ResultCode: resultCode,
|
ResultCode: resultCode,
|
||||||
RecvID: v,
|
RecvID: v,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user