management modify

This commit is contained in:
Gordon 2021-12-28 20:44:19 +08:00
parent 1e50556f64
commit 8cfc5925da
10 changed files with 263 additions and 284 deletions

View File

@ -26,7 +26,6 @@ func main() {
{ {
userRouterGroup.POST("/update_user_info", user.UpdateUserInfo) userRouterGroup.POST("/update_user_info", user.UpdateUserInfo)
userRouterGroup.POST("/get_user_info", user.GetUserInfo) userRouterGroup.POST("/get_user_info", user.GetUserInfo)
//userRouterGroup.POST("/get_users_online_status", user.GetUsersOnlineStatus)
} }
//friend routing group //friend routing group
friendRouterGroup := r.Group("/friend") friendRouterGroup := r.Group("/friend")
@ -87,9 +86,9 @@ func main() {
{ {
managementGroup.POST("/delete_user", manage.DeleteUser) managementGroup.POST("/delete_user", manage.DeleteUser)
managementGroup.POST("/send_msg", manage.ManagementSendMsg) managementGroup.POST("/send_msg", manage.ManagementSendMsg)
// managementGroup.POST("/get_all_users_uid", manage.GetAllUsersUid) managementGroup.POST("/get_all_users_uid", manage.GetAllUsersUid)
// managementGroup.POST("/account_check", manage.AccountCheck) managementGroup.POST("/account_check", manage.AccountCheck)
// managementGroup.POST("/get_users_online_status", manage.GetUsersOnlineStatus) managementGroup.POST("/get_users_online_status", manage.GetUsersOnlineStatus)
} }
//Conversation //Conversation
conversationGroup := r.Group("/conversation") conversationGroup := r.Group("/conversation")

View File

@ -6,154 +6,175 @@
*/ */
package manage package manage
import "github.com/gin-gonic/gin" import (
api "Open_IM/pkg/base_info"
"Open_IM/pkg/common/config"
"Open_IM/pkg/common/constant"
"Open_IM/pkg/common/log"
"Open_IM/pkg/common/token_verify"
"Open_IM/pkg/grpc-etcdv3/getcdv3"
pbRelay "Open_IM/pkg/proto/relay"
rpc "Open_IM/pkg/proto/user"
"Open_IM/pkg/utils"
"context"
"github.com/gin-gonic/gin"
"net/http"
"strings"
)
func DeleteUser(c *gin.Context) { func DeleteUser(c *gin.Context) {
params := api.DeleteUsersReq{}
if err := c.BindJSON(&params); err != nil {
c.JSON(http.StatusBadRequest, gin.H{"errCode": 400, "errMsg": err.Error()})
return
}
req := &rpc.DeleteUsersReq{}
utils.CopyStructFields(req, &params)
var ok bool
ok, req.OpUserID = token_verify.GetUserIDFromToken(c.Request.Header.Get("token"))
if !ok {
log.NewError(req.OperationID, "GetUserIDFromToken false ", c.Request.Header.Get("token"))
c.JSON(http.StatusInternalServerError, gin.H{"errCode": 500, "errMsg": "GetUserIDFromToken failed"})
return
}
log.NewInfo(params.OperationID, "DeleteUser args ", req.String())
etcdConn := getcdv3.GetConn(config.Config.Etcd.EtcdSchema, strings.Join(config.Config.Etcd.EtcdAddr, ","), config.Config.RpcRegisterName.OpenImUserName)
client := rpc.NewUserClient(etcdConn)
RpcResp, err := client.DeleteUsers(context.Background(), req)
if err != nil {
log.NewError(req.OperationID, "call delete users rpc server failed", err.Error())
c.JSON(http.StatusInternalServerError, gin.H{"errCode": 500, "errMsg": "call delete users rpc server failed"})
return
}
failedUserIDList := make([]string, 0)
for _, v := range RpcResp.FailedUserIDList {
failedUserIDList = append(failedUserIDList, v)
}
resp := api.DeleteUsersResp{CommResp: api.CommResp{ErrCode: RpcResp.CommonResp.ErrCode, ErrMsg: RpcResp.CommonResp.ErrMsg}}
resp.FailedUserIDList = failedUserIDList
log.NewInfo(req.OperationID, "DeleteUser api return", resp)
c.JSON(http.StatusOK, resp)
}
func GetAllUsersUid(c *gin.Context) {
params := api.GetAllUsersUidReq{}
if err := c.BindJSON(&params); err != nil {
c.JSON(http.StatusBadRequest, gin.H{"errCode": 400, "errMsg": err.Error()})
return
}
req := &rpc.GetAllUserIDReq{}
utils.CopyStructFields(req, &params)
var ok bool
ok, req.OpUserID = token_verify.GetUserIDFromToken(c.Request.Header.Get("token"))
if !ok {
log.NewError(req.OperationID, "GetUserIDFromToken false ", c.Request.Header.Get("token"))
c.JSON(http.StatusInternalServerError, gin.H{"errCode": 500, "errMsg": "GetUserIDFromToken failed"})
return
}
log.NewInfo(params.OperationID, "GetAllUsersUid args ", req.String())
etcdConn := getcdv3.GetConn(config.Config.Etcd.EtcdSchema, strings.Join(config.Config.Etcd.EtcdAddr, ","), config.Config.RpcRegisterName.OpenImUserName)
client := rpc.NewUserClient(etcdConn)
RpcResp, err := client.GetAllUserID(context.Background(), req)
if err != nil {
log.NewError(req.OperationID, "call GetAllUsersUid users rpc server failed", err.Error())
c.JSON(http.StatusInternalServerError, gin.H{"errCode": 500, "errMsg": "call GetAllUsersUid users rpc server failed"})
return
}
userIDList := make([]string, 0)
for _, v := range RpcResp.UserIDList {
userIDList = append(userIDList, v)
}
resp := api.GetAllUsersUidResp{CommResp: api.CommResp{ErrCode: RpcResp.CommonResp.ErrCode, ErrMsg: RpcResp.CommonResp.ErrMsg}}
resp.UserIDList = userIDList
log.NewInfo(req.OperationID, "GetAllUsersUid api return", resp)
c.JSON(http.StatusOK, resp)
} }
func AccountCheck(c *gin.Context) {
params := api.AccountCheckReq{}
if err := c.BindJSON(&params); err != nil {
c.JSON(http.StatusBadRequest, gin.H{"errCode": 400, "errMsg": err.Error()})
return
}
req := &rpc.AccountCheckReq{}
utils.CopyStructFields(req, &params)
var ok bool
ok, req.OpUserID = token_verify.GetUserIDFromToken(c.Request.Header.Get("token"))
if !ok {
log.NewError(req.OperationID, "GetUserIDFromToken false ", c.Request.Header.Get("token"))
c.JSON(http.StatusInternalServerError, gin.H{"errCode": 500, "errMsg": "GetUserIDFromToken failed"})
return
}
log.NewInfo(params.OperationID, "AccountCheck args ", req.String())
etcdConn := getcdv3.GetConn(config.Config.Etcd.EtcdSchema, strings.Join(config.Config.Etcd.EtcdAddr, ","), config.Config.RpcRegisterName.OpenImUserName)
client := rpc.NewUserClient(etcdConn)
// RpcResp, err := client.AccountCheck(context.Background(), req)
//func DeleteUser(c *gin.Context) { if err != nil {
// params := paramsDeleteUsers{} log.NewError(req.OperationID, "call AccountCheck users rpc server failed", err.Error())
// if err := c.BindJSON(&params); err != nil { c.JSON(http.StatusInternalServerError, gin.H{"errCode": 500, "errMsg": "call AccountCheck users rpc server failed"})
// c.JSON(http.StatusBadRequest, gin.H{"errCode": 400, "errMsg": err.Error()}) return
// return }
// } resp := api.AccountCheckResp{CommResp: api.CommResp{ErrCode: RpcResp.CommonResp.ErrCode, ErrMsg: RpcResp.CommonResp.ErrMsg}}
// log.InfoByKv("DeleteUser req come here", params.OperationID, "DeleteUidList", params.DeleteUidList) resp.ResultList = RpcResp.ResultList
// etcdConn := getcdv3.GetConn(config.Config.Etcd.EtcdSchema, strings.Join(config.Config.Etcd.EtcdAddr, ","), config.Config.RpcRegisterName.OpenImUserName) log.NewInfo(req.OperationID, "AccountCheck api return", resp)
// client := pbUser.NewUserClient(etcdConn) c.JSON(http.StatusOK, resp)
// //defer etcdConn.Close() }
// func GetUsersOnlineStatus(c *gin.Context) {
// req := &pbUser.DeleteUsersReq{ params := api.GetUsersOnlineStatusReq{}
// OperationID: params.OperationID, if err := c.BindJSON(&params); err != nil {
// DeleteUidList: params.DeleteUidList, c.JSON(http.StatusBadRequest, gin.H{"errCode": 400, "errMsg": err.Error()})
// Token: c.Request.Header.Get("token"), return
// } }
// RpcResp, err := client.DeleteUsers(context.Background(), req) req := &pbRelay.GetUsersOnlineStatusReq{}
// if err != nil { utils.CopyStructFields(req, &params)
// log.NewError(req.OperationID, "call delete users rpc server failed", err.Error()) var ok bool
// c.JSON(http.StatusInternalServerError, gin.H{"errCode": 500, "errMsg": "call delete users rpc server failed"}) ok, req.OpUserID = token_verify.GetUserIDFromToken(c.Request.Header.Get("token"))
// return if !ok {
// } log.NewError(req.OperationID, "GetUserIDFromToken false ", c.Request.Header.Get("token"))
// failedUidList := make([]string, 0) c.JSON(http.StatusInternalServerError, gin.H{"errCode": 500, "errMsg": "GetUserIDFromToken failed"})
// for _, v := range RpcResp.FailedUidList { return
// failedUidList = append(failedUidList, v) }
// } log.NewInfo(params.OperationID, "GetUsersOnlineStatus args ", req.String())
// log.InfoByKv("call delete user rpc server is success", params.OperationID, "resp args", RpcResp.String()) var wsResult []*pbRelay.GetUsersOnlineStatusResp_SuccessResult
// resp := gin.H{"errCode": RpcResp.CommonResp.ErrorCode, "errMsg": RpcResp.CommonResp.ErrorMsg, "failedUidList": RpcResp.FailedUidList} var respResult []*pbRelay.GetUsersOnlineStatusResp_SuccessResult
// c.JSON(http.StatusOK, resp) flag := false
//} grpcCons := getcdv3.GetConn4Unique(config.Config.Etcd.EtcdSchema, strings.Join(config.Config.Etcd.EtcdAddr, ","), config.Config.RpcRegisterName.OpenImOnlineMessageRelayName)
//func GetAllUsersUid(c *gin.Context) { for _, v := range grpcCons {
// params := paramsGetAllUsersUid{} client := pbRelay.NewOnlineMessageRelayServiceClient(v)
// if err := c.BindJSON(&params); err != nil { reply, err := client.GetUsersOnlineStatus(context.Background(), req)
// c.JSON(http.StatusBadRequest, gin.H{"errCode": 400, "errMsg": err.Error()}) if err != nil {
// return log.NewError(params.OperationID, "GetUsersOnlineStatus rpc err", req.String(), err.Error())
// } continue
// log.InfoByKv("GetAllUsersUid req come here", params.OperationID) } else {
// etcdConn := getcdv3.GetConn(config.Config.Etcd.EtcdSchema, strings.Join(config.Config.Etcd.EtcdAddr, ","), config.Config.RpcRegisterName.OpenImUserName) if reply.ErrCode == 0 {
// client := pbUser.NewUserClient(etcdConn) wsResult = append(wsResult, reply.SuccessResult...)
// //defer etcdConn.Close() }
// }
// req := &pbUser.GetAllUsersUidReq{ }
// OperationID: params.OperationID, log.NewInfo(params.OperationID, "call GetUsersOnlineStatus rpc server is success", wsResult)
// Token: c.Request.Header.Get("token"), //Online data merge of each node
// } for _, v1 := range params.UserIDList {
// RpcResp, err := client.GetAllUsersUid(context.Background(), req) flag = false
// if err != nil { temp := new(pbRelay.GetUsersOnlineStatusResp_SuccessResult)
// c.JSON(http.StatusInternalServerError, gin.H{"errCode": 500, "errMsg": err.Error(), "uidList": []string{}}) for _, v2 := range wsResult {
// return if v2.UserID == v1 {
// } flag = true
// log.InfoByKv("call GetAllUsersUid rpc server is success", params.OperationID, "resp args", RpcResp.String()) temp.UserID = v1
// resp := gin.H{"errCode": RpcResp.CommonResp.ErrorCode, "errMsg": RpcResp.CommonResp.ErrorMsg, "uidList": RpcResp.UidList} temp.Status = constant.OnlineStatus
// c.JSON(http.StatusOK, resp) temp.DetailPlatformStatus = append(temp.DetailPlatformStatus, v2.DetailPlatformStatus...)
// }
//}
//func AccountCheck(c *gin.Context) { }
// params := paramsAccountCheck{} if !flag {
// if err := c.BindJSON(&params); err != nil { temp.UserID = v1
// c.JSON(http.StatusBadRequest, gin.H{"errCode": 400, "errMsg": err.Error()}) temp.Status = constant.OfflineStatus
// return }
// } respResult = append(respResult, temp)
// log.InfoByKv("AccountCheck req come here", params.OperationID, params.UserIDList) }
// etcdConn := getcdv3.GetConn(config.Config.Etcd.EtcdSchema, strings.Join(config.Config.Etcd.EtcdAddr, ","), config.Config.RpcRegisterName.OpenImUserName) resp := api.GetUsersOnlineStatusResp{CommResp: api.CommResp{ErrCode: 0, ErrMsg: ""}}
// client := pbUser.NewUserClient(etcdConn) resp.SuccessResult = respResult
// //defer etcdConn.Close() log.NewInfo(req.OperationID, "GetUsersOnlineStatus api return", resp)
// c.JSON(http.StatusOK, resp)
// req := &pbUser.AccountCheckReq{
// OperationID: params.OperationID, }
// Token: c.Request.Header.Get("token"),
// UidList: params.UserIDList,
// }
// RpcResp, err := client.AccountCheck(context.Background(), req)
// if err != nil {
// c.JSON(http.StatusInternalServerError, gin.H{"errCode": 500, "errMsg": err.Error()})
// return
// }
// log.InfoByKv("call AccountCheck rpc server is success", params.OperationID, "resp args", RpcResp.String())
// resp := gin.H{"errCode": RpcResp.CommonResp.ErrorCode, "errMsg": RpcResp.CommonResp.ErrorMsg, "result": RpcResp.Result}
// c.JSON(http.StatusOK, resp)
//
//}
//func GetUsersOnlineStatus(c *gin.Context) {
// params := paramsGetUsersOnlineStatus{}
// if err := c.BindJSON(&params); err != nil {
// c.JSON(http.StatusBadRequest, gin.H{"errCode": 400, "errMsg": err.Error()})
// return
// }
// claims, err := token_verify.ParseToken(c.Request.Header.Get("token"))
// if err != nil {
// log.ErrorByKv("parse token failed", params.OperationID, "err", err.Error())
// c.JSON(http.StatusBadRequest, gin.H{"errCode": 401, "errMsg": err.Error()})
// return
// }
// if !utils.IsContain(claims.UID, config.Config.Manager.AppManagerUid) {
// log.ErrorByKv(" Authentication failed", params.OperationID, "args", c)
// c.JSON(http.StatusBadRequest, gin.H{"errCode": 402, "errMsg": "not authorized"})
// return
// }
// req := &pbRelay.GetUsersOnlineStatusReq{
// OperationID: params.OperationID,
// UserIDList: params.UserIDList,
// }
// var wsResult []*pbRelay.GetUsersOnlineStatusResp_SuccessResult
// var respResult []*pbRelay.GetUsersOnlineStatusResp_SuccessResult
// flag := false
// log.NewDebug(params.OperationID, "GetUsersOnlineStatus req come here", params.UserIDList)
// grpcCons := getcdv3.GetConn4Unique(config.Config.Etcd.EtcdSchema, strings.Join(config.Config.Etcd.EtcdAddr, ","), config.Config.RpcRegisterName.OpenImOnlineMessageRelayName)
// for _, v := range grpcCons {
// client := pbRelay.NewOnlineMessageRelayServiceClient(v)
// reply, err := client.GetUsersOnlineStatus(context.Background(), req)
// if err != nil {
// log.NewError(params.OperationID, "GetUsersOnlineStatus rpc err", req.String(), err.Error())
// continue
// } else {
// if reply.ErrCode == 0 {
// wsResult = append(wsResult, reply.SuccessResult...)
// }
// }
// }
// log.NewDebug(params.OperationID, "call GetUsersOnlineStatus rpc server is success", wsResult)
// //Online data merge of each node
// for _, v1 := range params.UserIDList {
// flag = false
// temp := new(pbRelay.GetUsersOnlineStatusResp_SuccessResult)
// for _, v2 := range wsResult {
// if v2.UserID == v1 {
// flag = true
// temp.UserID = v1
// temp.Status = constant.OnlineStatus
// temp.DetailPlatformStatus = append(temp.DetailPlatformStatus, v2.DetailPlatformStatus...)
// }
//
// }
// if !flag {
// temp.UserID = v1
// temp.Status = constant.OfflineStatus
// }
// respResult = append(respResult, temp)
// }
// log.NewDebug(params.OperationID, "Finished merged data", respResult)
// resp := gin.H{"errCode": 0, "errMsg": "", "successResult": respResult}
// c.JSON(http.StatusOK, resp)
//
//}

View File

@ -14,68 +14,6 @@ import (
"strings" "strings"
) )
//
//func GetUsersOnlineStatus(c *gin.Context) {
// params := api.GetUsersOnlineStatusReq{}
// if err := c.BindJSON(&params); err != nil {
// log.NewError(params.OperationID, "bind json failed ", err.Error(), c)
// c.JSON(http.StatusBadRequest, gin.H{"errCode": 400, "errMsg": err.Error()})
// return
// }
//
// if params.Secret != config.Config.Secret {
// log.NewError(params.OperationID, "parse token failed ", params.Secret, config.Config.Secret)
// c.JSON(http.StatusBadRequest, gin.H{"errCode": 401, "errMsg": "secret failed"})
// return
// }
//
// req := &pbRelay.GetUsersOnlineStatusReq{
// OperationID: params.OperationID,
// UserIDList: params.UserIDList,
// }
// var wsResult []*rpc.GetUsersOnlineStatusResp_SuccessResult
// var respResult []*rpc.GetUsersOnlineStatusResp_SuccessResult
// flag := false
// log.NewDebug(params.OperationID, "GetUsersOnlineStatus req come here", params.UserIDList)
//
// grpcCons := getcdv3.GetConn4Unique(config.Config.Etcd.EtcdSchema, strings.Join(config.Config.Etcd.EtcdAddr, ","), config.Config.RpcRegisterName.OpenImOnlineMessageRelayName)
// for _, v := range grpcCons {
// client := rpc.NewOnlineMessageRelayServiceClient(v)
// reply, err := client.GetUsersOnlineStatus(context.Background(), req)
// if err != nil {
// log.NewError(params.OperationID, "GetUsersOnlineStatus rpc err", req.String(), err.Error())
// continue
// } else {
// if reply.ErrCode == 0 {
// wsResult = append(wsResult, reply.SuccessResult...)
// }
// }
// }
// log.NewDebug(params.OperationID, "call GetUsersOnlineStatus rpc server is success", wsResult)
// //Online data merge of each node
// for _, v1 := range params.UserIDList {
// flag = false
// temp := new(pbRelay.GetUsersOnlineStatusResp_SuccessResult)
// for _, v2 := range wsResult {
// if v2.UserID == v1 {
// flag = true
// temp.UserID = v1
// temp.Status = constant.OnlineStatus
// temp.DetailPlatformStatus = append(temp.DetailPlatformStatus, v2.DetailPlatformStatus...)
// }
// }
// if !flag {
// temp.UserID = v1
// temp.Status = constant.OfflineStatus
// }
// respResult = append(respResult, temp)
// }
// log.NewDebug(params.OperationID, "Finished merged data", respResult)
// resp := gin.H{"errCode": 0, "errMsg": "", "data": respResult}
//
// c.JSON(http.StatusOK, resp)
//}
func GetUserInfo(c *gin.Context) { func GetUserInfo(c *gin.Context) {
params := api.GetUserInfoReq{} params := api.GetUserInfoReq{}
if err := c.BindJSON(&params); err != nil { if err := c.BindJSON(&params); err != nil {
@ -83,7 +21,7 @@ func GetUserInfo(c *gin.Context) {
return return
} }
req := &rpc.GetUserInfoReq{} req := &rpc.GetUserInfoReq{}
utils.CopyStructFields(&req, params) utils.CopyStructFields(req, &params)
var ok bool var ok bool
ok, req.OpUserID = token_verify.GetUserIDFromToken(c.Request.Header.Get("token")) ok, req.OpUserID = token_verify.GetUserIDFromToken(c.Request.Header.Get("token"))
if !ok { if !ok {

View File

@ -151,7 +151,6 @@ func (ws *WServer) pullMsgResp(conn *UserConn, m *Req, pb *sdk_ws.PullMessageRes
} }
c, err := proto.Marshal(&mReplyData) c, err := proto.Marshal(&mReplyData)
log.NewInfo(m.OperationID, "test info is ", len(mReplyData.SingleUserMsg), mReplyData.SingleUserMsg) log.NewInfo(m.OperationID, "test info is ", len(mReplyData.SingleUserMsg), mReplyData.SingleUserMsg)
mReply := Resp{ mReply := Resp{
ReqIdentifier: m.ReqIdentifier, ReqIdentifier: m.ReqIdentifier,
MsgIncr: m.MsgIncr, MsgIncr: m.MsgIncr,
@ -162,7 +161,6 @@ func (ws *WServer) pullMsgResp(conn *UserConn, m *Req, pb *sdk_ws.PullMessageRes
} }
log.NewInfo(m.OperationID, "pullMsgResp all data is ", mReply.ReqIdentifier, mReply.MsgIncr, mReply.ErrCode, mReply.ErrMsg, log.NewInfo(m.OperationID, "pullMsgResp all data is ", mReply.ReqIdentifier, mReply.MsgIncr, mReply.ErrCode, mReply.ErrMsg,
len(mReply.Data)) len(mReply.Data))
ws.sendMsg(conn, mReply) ws.sendMsg(conn, mReply)
} }

View File

@ -4,6 +4,7 @@ import (
"Open_IM/pkg/common/config" "Open_IM/pkg/common/config"
"Open_IM/pkg/common/constant" "Open_IM/pkg/common/constant"
"Open_IM/pkg/common/log" "Open_IM/pkg/common/log"
"Open_IM/pkg/common/token_verify"
"Open_IM/pkg/grpc-etcdv3/getcdv3" "Open_IM/pkg/grpc-etcdv3/getcdv3"
pbRelay "Open_IM/pkg/proto/relay" pbRelay "Open_IM/pkg/proto/relay"
"Open_IM/pkg/utils" "Open_IM/pkg/utils"
@ -105,7 +106,11 @@ func (r *RPCServer) OnlinePushMsg(_ context.Context, in *pbRelay.OnlinePushMsgRe
}, nil }, nil
} }
func (r *RPCServer) GetUsersOnlineStatus(_ context.Context, req *pbRelay.GetUsersOnlineStatusReq) (*pbRelay.GetUsersOnlineStatusResp, error) { func (r *RPCServer) GetUsersOnlineStatus(_ context.Context, req *pbRelay.GetUsersOnlineStatusReq) (*pbRelay.GetUsersOnlineStatusResp, error) {
log.NewDebug(req.OperationID, "rpc GetUsersOnlineStatus arrived server", req.String()) log.NewInfo(req.OperationID, "rpc GetUsersOnlineStatus arrived server", req.String())
if !token_verify.IsMangerUserID(req.OpUserID) {
log.NewError(req.OperationID, "no permission GetUsersOnlineStatus ", req.OpUserID)
return &pbRelay.GetUsersOnlineStatusResp{ErrCode: constant.ErrAccess.ErrCode, ErrMsg: constant.ErrAccess.ErrMsg}, nil
}
var resp pbRelay.GetUsersOnlineStatusResp var resp pbRelay.GetUsersOnlineStatusResp
for _, userID := range req.UserIDList { for _, userID := range req.UserIDList {
platformList := genPlatformArray() platformList := genPlatformArray()
@ -125,6 +130,7 @@ func (r *RPCServer) GetUsersOnlineStatus(_ context.Context, req *pbRelay.GetUser
resp.SuccessResult = append(resp.SuccessResult, temp) resp.SuccessResult = append(resp.SuccessResult, temp)
} }
} }
log.NewInfo(req.OperationID, "GetUsersOnlineStatus rpc return ", resp.String())
return &resp, nil return &resp, nil
} }
func sendMsgToUser(conn *UserConn, bMsg []byte, in *pbRelay.OnlinePushMsgReq, RecvPlatForm, RecvID string) (ResultCode int64) { func sendMsgToUser(conn *UserConn, bMsg []byte, in *pbRelay.OnlinePushMsgReq, RecvPlatForm, RecvID string) (ResultCode int64) {

View File

@ -141,10 +141,12 @@ func (rpc *rpcChat) SendMsg(_ context.Context, pb *pbChat.SendMsgReq) (*pbChat.S
return returnMsg(&replay, pb, 201, "kafka send msg err", "", 0) return returnMsg(&replay, pb, 201, "kafka send msg err", "", 0)
} }
} }
err2 := rpc.sendMsgToKafka(&msgToMQ, msgToMQ.MsgData.SendID) if msgToMQ.MsgData.SendID != msgToMQ.MsgData.RecvID { //Filter messages sent to yourself
if err2 != nil { err2 := rpc.sendMsgToKafka(&msgToMQ, msgToMQ.MsgData.SendID)
log.NewError(msgToMQ.OperationID, "kafka send msg err:SendID", msgToMQ.MsgData.SendID, msgToMQ.String()) if err2 != nil {
return returnMsg(&replay, pb, 201, "kafka send msg err", "", 0) log.NewError(msgToMQ.OperationID, "kafka send msg err:SendID", msgToMQ.MsgData.SendID, msgToMQ.String())
return returnMsg(&replay, pb, 201, "kafka send msg err", "", 0)
}
} }
return returnMsg(&replay, pb, 0, "", msgToMQ.MsgData.ServerMsgID, msgToMQ.MsgData.SendTime) return returnMsg(&replay, pb, 0, "", msgToMQ.MsgData.ServerMsgID, msgToMQ.MsgData.SendTime)
case constant.GroupChatType: case constant.GroupChatType:

View File

@ -1,6 +1,10 @@
package base_info package base_info
import open_im_sdk "Open_IM/pkg/proto/sdk_ws" import (
pbRelay "Open_IM/pkg/proto/relay"
open_im_sdk "Open_IM/pkg/proto/sdk_ws"
pbUser "Open_IM/pkg/proto/user"
)
type paramsManagementSendMsg struct { type paramsManagementSendMsg struct {
OperationID string `json:"operationID" binding:"required"` OperationID string `json:"operationID" binding:"required"`
@ -62,21 +66,37 @@ type FileElem struct {
FileSize int64 `mapstructure:"fileSize"` FileSize int64 `mapstructure:"fileSize"`
} }
type paramsDeleteUsers struct { type DeleteUsersReq struct {
OperationID string `json:"operationID" binding:"required"` OperationID string `json:"operationID" binding:"required"`
DeleteUidList []string `json:"deleteUidList" binding:"required"` DeleteUidList []string `json:"deleteUidList" binding:"required"`
} }
type paramsGetAllUsersUid struct { type DeleteUsersResp struct {
CommResp
FailedUserIDList []string `json:"data"`
}
type GetAllUsersUidReq struct {
OperationID string `json:"operationID" binding:"required"` OperationID string `json:"operationID" binding:"required"`
} }
type paramsGetUsersOnlineStatus struct { type GetAllUsersUidResp struct {
CommResp
UserIDList []string `json:"data"`
}
type GetUsersOnlineStatusReq struct {
OperationID string `json:"operationID" binding:"required"` OperationID string `json:"operationID" binding:"required"`
UserIDList []string `json:"userIDList" binding:"required,lte=200"` UserIDList []string `json:"userIDList" binding:"required,lte=200"`
} }
type paramsAccountCheck struct { type GetUsersOnlineStatusResp struct {
CommResp
SuccessResult []*pbRelay.GetUsersOnlineStatusResp_SuccessResult `json:"data"`
}
type AccountCheckReq struct {
OperationID string `json:"operationID" binding:"required"` OperationID string `json:"operationID" binding:"required"`
UserIDList []string `json:"userIDList" binding:"required,lte=100"` UserIDList []string `json:"userIDList" binding:"required,lte=100"`
} }
type AccountCheckResp struct {
CommResp
ResultList []*pbUser.AccountCheckResp_SingleUserStatus `json:"data"`
}
type AtElem struct { type AtElem struct {
Text string `mapstructure:"text"` Text string `mapstructure:"text"`

View File

@ -4,20 +4,6 @@ import (
open_im_sdk "Open_IM/pkg/proto/sdk_ws" open_im_sdk "Open_IM/pkg/proto/sdk_ws"
) )
type GetUsersOnlineStatusReq struct {
OperationID string `json:"operationID" binding:"required"`
UserIDList []string `json:"userIDList" binding:"required,lte=200"`
Secret string `json:"secret" binding:"required,max=32"`
}
type OnlineStatus struct {
UserID string `json:"userID"`
Status string `json:"status"`
}
type GetUsersOnlineStatusResp struct {
CommResp
OnlineStatusList []*OnlineStatus `json:"data"`
}
type GetUserInfoReq struct { type GetUserInfoReq struct {
OperationID string `json:"operationID" binding:"required"` OperationID string `json:"operationID" binding:"required"`
UserIDList []string `json:"userIDList" binding:"required"` UserIDList []string `json:"userIDList" binding:"required"`

View File

@ -36,7 +36,7 @@ func (m *OnlinePushMsgReq) Reset() { *m = OnlinePushMsgReq{} }
func (m *OnlinePushMsgReq) String() string { return proto.CompactTextString(m) } func (m *OnlinePushMsgReq) String() string { return proto.CompactTextString(m) }
func (*OnlinePushMsgReq) ProtoMessage() {} func (*OnlinePushMsgReq) ProtoMessage() {}
func (*OnlinePushMsgReq) Descriptor() ([]byte, []int) { func (*OnlinePushMsgReq) Descriptor() ([]byte, []int) {
return fileDescriptor_relay_f80d9497f96c724f, []int{0} return fileDescriptor_relay_de3bbbc2d62c0c49, []int{0}
} }
func (m *OnlinePushMsgReq) XXX_Unmarshal(b []byte) error { func (m *OnlinePushMsgReq) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_OnlinePushMsgReq.Unmarshal(m, b) return xxx_messageInfo_OnlinePushMsgReq.Unmarshal(m, b)
@ -81,7 +81,7 @@ func (m *OnlinePushMsgResp) Reset() { *m = OnlinePushMsgResp{} }
func (m *OnlinePushMsgResp) String() string { return proto.CompactTextString(m) } func (m *OnlinePushMsgResp) String() string { return proto.CompactTextString(m) }
func (*OnlinePushMsgResp) ProtoMessage() {} func (*OnlinePushMsgResp) ProtoMessage() {}
func (*OnlinePushMsgResp) Descriptor() ([]byte, []int) { func (*OnlinePushMsgResp) Descriptor() ([]byte, []int) {
return fileDescriptor_relay_f80d9497f96c724f, []int{1} return fileDescriptor_relay_de3bbbc2d62c0c49, []int{1}
} }
func (m *OnlinePushMsgResp) XXX_Unmarshal(b []byte) error { func (m *OnlinePushMsgResp) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_OnlinePushMsgResp.Unmarshal(m, b) return xxx_messageInfo_OnlinePushMsgResp.Unmarshal(m, b)
@ -121,7 +121,7 @@ func (m *SingleMsgToUser) Reset() { *m = SingleMsgToUser{} }
func (m *SingleMsgToUser) String() string { return proto.CompactTextString(m) } func (m *SingleMsgToUser) String() string { return proto.CompactTextString(m) }
func (*SingleMsgToUser) ProtoMessage() {} func (*SingleMsgToUser) ProtoMessage() {}
func (*SingleMsgToUser) Descriptor() ([]byte, []int) { func (*SingleMsgToUser) Descriptor() ([]byte, []int) {
return fileDescriptor_relay_f80d9497f96c724f, []int{2} return fileDescriptor_relay_de3bbbc2d62c0c49, []int{2}
} }
func (m *SingleMsgToUser) XXX_Unmarshal(b []byte) error { func (m *SingleMsgToUser) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_SingleMsgToUser.Unmarshal(m, b) return xxx_messageInfo_SingleMsgToUser.Unmarshal(m, b)
@ -165,6 +165,7 @@ func (m *SingleMsgToUser) GetRecvPlatFormID() int32 {
type GetUsersOnlineStatusReq struct { type GetUsersOnlineStatusReq struct {
UserIDList []string `protobuf:"bytes,1,rep,name=userIDList" json:"userIDList,omitempty"` UserIDList []string `protobuf:"bytes,1,rep,name=userIDList" json:"userIDList,omitempty"`
OperationID string `protobuf:"bytes,2,opt,name=operationID" json:"operationID,omitempty"` OperationID string `protobuf:"bytes,2,opt,name=operationID" json:"operationID,omitempty"`
OpUserID string `protobuf:"bytes,3,opt,name=opUserID" json:"opUserID,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"` XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"` XXX_sizecache int32 `json:"-"`
@ -174,7 +175,7 @@ func (m *GetUsersOnlineStatusReq) Reset() { *m = GetUsersOnlineStatusReq
func (m *GetUsersOnlineStatusReq) String() string { return proto.CompactTextString(m) } func (m *GetUsersOnlineStatusReq) String() string { return proto.CompactTextString(m) }
func (*GetUsersOnlineStatusReq) ProtoMessage() {} func (*GetUsersOnlineStatusReq) ProtoMessage() {}
func (*GetUsersOnlineStatusReq) Descriptor() ([]byte, []int) { func (*GetUsersOnlineStatusReq) Descriptor() ([]byte, []int) {
return fileDescriptor_relay_f80d9497f96c724f, []int{3} return fileDescriptor_relay_de3bbbc2d62c0c49, []int{3}
} }
func (m *GetUsersOnlineStatusReq) XXX_Unmarshal(b []byte) error { func (m *GetUsersOnlineStatusReq) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_GetUsersOnlineStatusReq.Unmarshal(m, b) return xxx_messageInfo_GetUsersOnlineStatusReq.Unmarshal(m, b)
@ -208,6 +209,13 @@ func (m *GetUsersOnlineStatusReq) GetOperationID() string {
return "" return ""
} }
func (m *GetUsersOnlineStatusReq) GetOpUserID() string {
if m != nil {
return m.OpUserID
}
return ""
}
type GetUsersOnlineStatusResp struct { type GetUsersOnlineStatusResp struct {
ErrCode int32 `protobuf:"varint,1,opt,name=errCode" json:"errCode,omitempty"` ErrCode int32 `protobuf:"varint,1,opt,name=errCode" json:"errCode,omitempty"`
ErrMsg string `protobuf:"bytes,2,opt,name=errMsg" json:"errMsg,omitempty"` ErrMsg string `protobuf:"bytes,2,opt,name=errMsg" json:"errMsg,omitempty"`
@ -222,7 +230,7 @@ func (m *GetUsersOnlineStatusResp) Reset() { *m = GetUsersOnlineStatusRe
func (m *GetUsersOnlineStatusResp) String() string { return proto.CompactTextString(m) } func (m *GetUsersOnlineStatusResp) String() string { return proto.CompactTextString(m) }
func (*GetUsersOnlineStatusResp) ProtoMessage() {} func (*GetUsersOnlineStatusResp) ProtoMessage() {}
func (*GetUsersOnlineStatusResp) Descriptor() ([]byte, []int) { func (*GetUsersOnlineStatusResp) Descriptor() ([]byte, []int) {
return fileDescriptor_relay_f80d9497f96c724f, []int{4} return fileDescriptor_relay_de3bbbc2d62c0c49, []int{4}
} }
func (m *GetUsersOnlineStatusResp) XXX_Unmarshal(b []byte) error { func (m *GetUsersOnlineStatusResp) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_GetUsersOnlineStatusResp.Unmarshal(m, b) return xxx_messageInfo_GetUsersOnlineStatusResp.Unmarshal(m, b)
@ -284,7 +292,7 @@ func (m *GetUsersOnlineStatusResp_SuccessDetail) Reset() {
func (m *GetUsersOnlineStatusResp_SuccessDetail) String() string { return proto.CompactTextString(m) } func (m *GetUsersOnlineStatusResp_SuccessDetail) String() string { return proto.CompactTextString(m) }
func (*GetUsersOnlineStatusResp_SuccessDetail) ProtoMessage() {} func (*GetUsersOnlineStatusResp_SuccessDetail) ProtoMessage() {}
func (*GetUsersOnlineStatusResp_SuccessDetail) Descriptor() ([]byte, []int) { func (*GetUsersOnlineStatusResp_SuccessDetail) Descriptor() ([]byte, []int) {
return fileDescriptor_relay_f80d9497f96c724f, []int{4, 0} return fileDescriptor_relay_de3bbbc2d62c0c49, []int{4, 0}
} }
func (m *GetUsersOnlineStatusResp_SuccessDetail) XXX_Unmarshal(b []byte) error { func (m *GetUsersOnlineStatusResp_SuccessDetail) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_GetUsersOnlineStatusResp_SuccessDetail.Unmarshal(m, b) return xxx_messageInfo_GetUsersOnlineStatusResp_SuccessDetail.Unmarshal(m, b)
@ -331,7 +339,7 @@ func (m *GetUsersOnlineStatusResp_FailedDetail) Reset() { *m = GetUsersO
func (m *GetUsersOnlineStatusResp_FailedDetail) String() string { return proto.CompactTextString(m) } func (m *GetUsersOnlineStatusResp_FailedDetail) String() string { return proto.CompactTextString(m) }
func (*GetUsersOnlineStatusResp_FailedDetail) ProtoMessage() {} func (*GetUsersOnlineStatusResp_FailedDetail) ProtoMessage() {}
func (*GetUsersOnlineStatusResp_FailedDetail) Descriptor() ([]byte, []int) { func (*GetUsersOnlineStatusResp_FailedDetail) Descriptor() ([]byte, []int) {
return fileDescriptor_relay_f80d9497f96c724f, []int{4, 1} return fileDescriptor_relay_de3bbbc2d62c0c49, []int{4, 1}
} }
func (m *GetUsersOnlineStatusResp_FailedDetail) XXX_Unmarshal(b []byte) error { func (m *GetUsersOnlineStatusResp_FailedDetail) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_GetUsersOnlineStatusResp_FailedDetail.Unmarshal(m, b) return xxx_messageInfo_GetUsersOnlineStatusResp_FailedDetail.Unmarshal(m, b)
@ -387,7 +395,7 @@ func (m *GetUsersOnlineStatusResp_SuccessResult) Reset() {
func (m *GetUsersOnlineStatusResp_SuccessResult) String() string { return proto.CompactTextString(m) } func (m *GetUsersOnlineStatusResp_SuccessResult) String() string { return proto.CompactTextString(m) }
func (*GetUsersOnlineStatusResp_SuccessResult) ProtoMessage() {} func (*GetUsersOnlineStatusResp_SuccessResult) ProtoMessage() {}
func (*GetUsersOnlineStatusResp_SuccessResult) Descriptor() ([]byte, []int) { func (*GetUsersOnlineStatusResp_SuccessResult) Descriptor() ([]byte, []int) {
return fileDescriptor_relay_f80d9497f96c724f, []int{4, 2} return fileDescriptor_relay_de3bbbc2d62c0c49, []int{4, 2}
} }
func (m *GetUsersOnlineStatusResp_SuccessResult) XXX_Unmarshal(b []byte) error { func (m *GetUsersOnlineStatusResp_SuccessResult) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_GetUsersOnlineStatusResp_SuccessResult.Unmarshal(m, b) return xxx_messageInfo_GetUsersOnlineStatusResp_SuccessResult.Unmarshal(m, b)
@ -544,42 +552,42 @@ var _OnlineMessageRelayService_serviceDesc = grpc.ServiceDesc{
Metadata: "relay/relay.proto", Metadata: "relay/relay.proto",
} }
func init() { proto.RegisterFile("relay/relay.proto", fileDescriptor_relay_f80d9497f96c724f) } func init() { proto.RegisterFile("relay/relay.proto", fileDescriptor_relay_de3bbbc2d62c0c49) }
var fileDescriptor_relay_f80d9497f96c724f = []byte{ var fileDescriptor_relay_de3bbbc2d62c0c49 = []byte{
// 531 bytes of a gzipped FileDescriptorProto // 539 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x94, 0x54, 0x5f, 0x6f, 0xd2, 0x50, 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x94, 0x54, 0x5f, 0x8f, 0xd2, 0x40,
0x14, 0x4f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 0x78, 0x8a, 0xec, 0x02, 0xea,
0x1d, 0x7b, 0xff, 0x80, 0x52, 0xf6, 0x05, 0x5a, 0xfb, 0x14, 0xb2, 0xf6, 0x7f, 0xe5, 0xaf, 0x9c, 0x5b, 0x1f, 0x21, 0x3b, 0x2f, 0x38, 0x77, 0x2f, 0x00, 0xc7, 0xde, 0x3f, 0x20, 0xc1, 0xbe, 0x42,
0xe7, 0xf7, 0xd8, 0x3b, 0x6f, 0x7e, 0x3b, 0x71, 0xcd, 0x35, 0xf5, 0x2e, 0xbd, 0xd2, 0xb2, 0xaf, 0x73, 0x9f, 0x42, 0xd6, 0xfa, 0xaf, 0xfc, 0xa5, 0xf3, 0xf2, 0x01, 0x7b, 0x17, 0x8d, 0xef, 0xa7,
0x0e, 0xf5, 0x2d, 0xf4, 0xf6, 0x6f, 0x00, 0x00, 0x00, 0xff, 0xff, 0x81, 0xe6, 0x3c, 0x27, 0xc4, 0xae, 0xb9, 0xc2, 0x3e, 0x88, 0x1b, 0x2d, 0xfb, 0xe6, 0x48, 0xdf, 0x50, 0xef, 0xff, 0x06, 0x00,
0x04, 0x00, 0x00, 0x00, 0xff, 0xff, 0x6d, 0x5a, 0x23, 0x8f, 0xe0, 0x04, 0x00, 0x00,
} }

View File

@ -29,6 +29,7 @@ message SingleMsgToUser{
message GetUsersOnlineStatusReq{ message GetUsersOnlineStatusReq{
repeated string userIDList = 1; repeated string userIDList = 1;
string operationID = 2; string operationID = 2;
string opUserID = 3;
} }
message GetUsersOnlineStatusResp{ message GetUsersOnlineStatusResp{
int32 errCode = 1; int32 errCode = 1;