[1.1 target] Scalar gameserver

Issue #9 new
Stian Andreassen created an issue

This is the answer for the performance question which always arises.

So, currently you can function on one gameserver, and in general only on one thread (true for TFS as well), and a thread based approch wouldn't function very well due to the global nature of the game world. You would have a huge lose to locks for every thread. Not to mension a very problematic core, the classic 10k problems.

However, one approch is to have all traffic pass to a mini proxy, this mini proxy will in turn send the traffic to a different process. Thus, we have full process scaling, the server do need to communicate, etc when one player passes from one servers area to another. But this overhead should be small, especially if game runners draw the server border lines manuelly in a smart way (so you avoid having the most crowded pieces of server crossing the line). Then we might have a 5-10% lose of performance due to the interprocess communication.

This can also scale to entierly different servers, and would allow the server to crash and you can still restart and restore (with smarter save of monsters you might notice half a second "lag" while the server restarts) and be right back in action.

While it's not very smart to do cross server connections across the country, inter serverhall connections are often <0.01ms which is more than acceptable.

This basically allows the server to grow to infinate sizes and it won't mater if you have a million slow scripts and the server use 5% CPU per player, each server would still be able to handle hundred connections, and you can always add more. True scalability. This even allows you to use super cheap DDoS VPS as the proxy only require line capacity, not much ram or cpu.

While the proxy might only be able to handle say 5-8k connections, you can add more by having two proxy servers (they don't need to communicate anything), and just pick different game proxy servers from the login server.

Comments (0)

  1. Log in to comment