Nakama appears to offer only one configurable max size value, socket.max_request_size_bytes. However, the intended max size can differ across sockets, RPCs, and admin RPCs.
Example intended max size per type:
| Type | Max size |
|---|---|
| Socket | Small |
| RPC | Medium |
| Admin RPC | Large |
We must set the max size to facilitate the largest size needed (e.g., admin RPCs with large config exports). However, this inadvertently increases the max size for other types, such as regular gameplay socket and RPC communication, which is not intended.
According to one of Nakama’s developers:
You should adjust this value for your game to match an upper limit on what you expect the size of your largest data message would look like. The reason we have this value is to protect against an attack vector known as a distributed “slow clients” attack.
Therefore, it would be beneficial to have more granular control over these settings, so that the larger sizes required for admin RPCs do not unintentionally increase the max sizes for regular gameplay sockets and RPCs.
Does Nakama have any solution to this, or any recommended alternative approach?