Monobit Unity Networking ver.2.8.0 Server API Reference (C++)
MunProxySessionToResolverServer.hpp
Go to the documentation of this file.
1 
7 #ifndef __MUN_PROXY_SESSION_TO_RESOLVER_SERVER_HPP__
8 #define __MUN_PROXY_SESSION_TO_RESOLVER_SERVER_HPP__
9 
10 #include <mrs.hpp>
11 #include <stream/MunStream.hpp>
13 
18 {
19 private:
21  static MrsConnection s_pConnectModule;
22 
24  static MrsConnection s_pResolverModule;
25 
27  static uint64 s_CheckTime;
28 
30  static std::string s_ResolverConnectAddress;
31 
33  static uint16 s_ResolverConnectPort;
34 
36  static int32 s_ResolverConnectTimeout;
37 
39  static bool s_IsRetryConnect;
40 
42  static std::string s_ClientListeningAddress;
43 
45  static uint16 s_ClientListeningPortTCP;
46 
48  static uint16 s_ClientListeningPortUDP;
49 
51  static uint16 s_ClientListeningPortWS;
52 
54  static uint16 s_ClientListeningPortWSS;
55 
56 
57  static STREAM::ProxyResolverSetWeightRequest s_ProxyResolverSetWeightRequest;
58  static STREAM::ProxyResolverSetAddressRequest s_ProxyResolverSetAddressRequest;
59 
60 
61 public:
67  static bool Initialize( MunProxyConfigure& configure );
68 
69 private:
74  static bool Connect();
75 
76 public:
81  static void Update(uint64 updateInterval);
82 
86  static void Finalize();
87 
93  static void Send_ProxyResolver_SetAddress( MrsConnection pMunResolver, STREAM::ProxyResolverSetAddressRequest &request );
94 
100  static void Send_ProxyResolver_SetWeight( MrsConnection pMunResolver, STREAM::ProxyResolverSetWeightRequest &request );
101 
102 private:
107  static void OnConnectCallback( MrsConnection pMunResolver, void* connection_data );
108 
113  static void OnDisconnectCallback( MrsConnection pMunResolver, void* connection_data );
114 
120  static void OnErrorCallback( MrsConnection pMunResolver, void* connection_data, MrsConnectionError status );
121 
131  static void OnReadRecordCallback( MrsConnection pMunResolver, void* connection_data, uint32 seqnum, uint16 options, uint16 payload_type, const void* payload, uint32 payload_len );
132 };
133 
134 #endif /* __MUN_PROXY_SESSION_TO_RESOLVER_SERVER_HPP__ */
static void Update(uint64 updateInterval)
更新処理(個別送信処理).
Definition: MunProxySessionToResolverServer.cpp:106
static void Send_ProxyResolver_SetAddress(MrsConnection pMunResolver, STREAM::ProxyResolverSetAddressRequest &request)
mrs_resolverに対し、mun_proxyサーバのクライアントリスニング情報を渡す.
Definition: MunProxySessionToResolverServer.cpp:156
mun_proxy サーバの設定.
Definition: MunProxyConfigure.hpp:29
mun_proxyサーバからmun_resolverサーバに対して送信される、mun_proxyサーバのアドレス情報.
Definition: MunStream.hpp:1863
MUNにおける通信データ情報.
static void Finalize()
終了処理.
Definition: MunProxySessionToResolverServer.cpp:140
static void Send_ProxyResolver_SetWeight(MrsConnection pMunResolver, STREAM::ProxyResolverSetWeightRequest &request)
mrs_resolverに対し、mun_proxyサーバの負荷の情報を渡す.
Definition: MunProxySessionToResolverServer.cpp:173
mun_proxyサーバの設定.
mun_resolverサーバとのネットワーク接続処理クラス.
Definition: MunProxySessionToResolverServer.hpp:17
static bool Initialize(MunProxyConfigure &configure)
初期化処理.
Definition: MunProxySessionToResolverServer.cpp:58
mun_proxyサーバからmun_resolverサーバに対して送信される、mun_proxyサーバの負荷情報.
Definition: MunStream.hpp:1965