1
This commit is contained in:
parent
3897376872
commit
d8987e654b
19
server/stat/proto/ss_msgid.proto
Normal file
19
server/stat/proto/ss_msgid.proto
Normal file
@ -0,0 +1,19 @@
|
||||
package ss;
|
||||
|
||||
//消息id定义
|
||||
enum SSMessageId_e
|
||||
{
|
||||
_SS_Ping = 8;
|
||||
_SS_Pong = 9;
|
||||
_SS_WSP_SocketDisconnect = 10;
|
||||
_SS_WSP_RequestTargetServer = 11;
|
||||
_SS_MS_ResponseTargetServer = 12;
|
||||
_SS_ForceCloseSocket = 13;
|
||||
|
||||
_SS_CMKcpHandshake = 99;
|
||||
_SS_CMPing = 101;
|
||||
_SS_SMRpcError = 102;
|
||||
_SS_CMLogin = 103;
|
||||
_SS_CMReconnect = 104;
|
||||
|
||||
}
|
101
server/stat/proto/ss_proto.proto
Normal file
101
server/stat/proto/ss_proto.proto
Normal file
@ -0,0 +1,101 @@
|
||||
package ss;
|
||||
|
||||
message SS_WSP_SocketDisconnect
|
||||
{
|
||||
}
|
||||
|
||||
message SS_CMPing
|
||||
{
|
||||
}
|
||||
|
||||
message SS_SMPing
|
||||
{
|
||||
optional int32 param1 = 1; optional int32 source = 2 [default = 0]; //0:tcp 1:udp
|
||||
}
|
||||
|
||||
message SS_CMLogin_CMReConnect_CommonHead
|
||||
{
|
||||
optional int32 server_id = 1;
|
||||
}
|
||||
|
||||
message SS_CMKcpHandshake
|
||||
{
|
||||
optional int32 proto_version = 1; //协议版本号Constant_e.ProtoVersion
|
||||
optional string account_id = 2; //账号id
|
||||
optional string session_id = 3; //session id
|
||||
optional string team_uuid = 4; //保留
|
||||
optional int32 secret_key_place = 5; //私钥存放位置 0:存在用户协议前(老) 1:存在kcp底层协议头之后(新)
|
||||
}
|
||||
|
||||
message SS_SMKcpHandshake
|
||||
{
|
||||
optional int32 errcode = 1; //errcode != 0时表示不支持kcp
|
||||
optional string errmsg = 2; //errmsg
|
||||
optional int32 conv = 3; //用来作为客户端的conv
|
||||
optional bytes secret_key = 4; //secret key客户端每次上报的时候加在包头之前
|
||||
optional string remote_host = 5; //host
|
||||
optional int32 remote_port = 6; //port
|
||||
}
|
||||
|
||||
message SS_CMLogin
|
||||
{
|
||||
optional int32 server_id = 1; //保留
|
||||
optional string team_uuid = 2; //保留
|
||||
optional string account_id = 3; //账号id
|
||||
optional int32 proto_version = 5; //协议版本号Constant_e.ProtoVersion
|
||||
optional string session_id = 20; //账号id
|
||||
}
|
||||
|
||||
message SS_CMReconnect
|
||||
{
|
||||
optional int32 server_id = 1; //保留
|
||||
optional string team_uuid = 2; //保留
|
||||
optional string account_id = 3; //账号id
|
||||
optional string session_id = 4; //session_id
|
||||
optional string room_uuid = 5; //房间唯一id
|
||||
optional string server_info = 6; //服务器信息
|
||||
}
|
||||
|
||||
message SS_WSP_RequestTargetServer
|
||||
{
|
||||
optional int64 context_id = 1;
|
||||
optional string account_id = 2;
|
||||
optional string team_id = 3;
|
||||
optional string server_info = 4;
|
||||
optional int32 is_reconnect = 5;
|
||||
optional int32 proto_version = 6; //协议版本号Constant_e.ProtoVersion
|
||||
optional string url = 7;
|
||||
optional string query_str = 8;
|
||||
optional string session_id = 9;
|
||||
}
|
||||
|
||||
message SS_MS_ResponseTargetServer
|
||||
{
|
||||
optional int32 error_code = 1;
|
||||
optional string error_msg = 2;
|
||||
optional int64 context_id = 3;
|
||||
optional string host = 4;
|
||||
optional int32 port = 5;
|
||||
}
|
||||
|
||||
message SS_SMRpcError
|
||||
{
|
||||
optional int32 error_code = 1;
|
||||
optional string error_msg = 2;
|
||||
optional string debug_msg = 3;
|
||||
optional string file = 4;
|
||||
optional int32 lineno = 5;
|
||||
}
|
||||
|
||||
message SS_Ping
|
||||
{
|
||||
}
|
||||
|
||||
message SS_Pong
|
||||
{
|
||||
optional int32 param1 = 1;
|
||||
}
|
||||
|
||||
message SS_ForceCloseSocket
|
||||
{
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user