CCU Limit
Posted: 16 Apr 2012, 22:04
We have a game which we have been developing and can't seem to get the user count to get much above 2000 ccu using an unlimited license. Our servers are barely being taxed (~3% CPU and ~200MB memory at peak) so it doesn't appear to be a hardware issue. I'm curious if anyone has any recommendations to increase concurrent users. One particular issue I'm uncertain of is whether it makes sense to be creating a new taskScheduler for each game room or have a master taskScheduler at the zone level that attempts to update each of the (potentially thousands) of rooms.
Below is a breakdown of roughly how our game works.
Our game is broken into two separate components, a lobby server and game server(s).
The lobby server is a single room that's only job is to match users. As each user enters the lobby they are added to a thread safe list. A taskScheduler is set to run once a second and match up users with valid opponents. If a match is made then both clients are given the IP address of a game server and a unique room name. They then disconnect from the lobby server and connect to the game server. If no match is made they remain in the lobby until someone arrives that they can play against.
The game server has a zone level extension that handles the arrival of new users by adding them to a thread safe list and running a task periodically which creates new rooms for each pair of players that have arrived. The users are then moved into their rooms and the game begins.
Each game room holds two players and awaits actions from the players. These actions are stored in a pair of lists. A taskScheduler is set to run every 3 seconds and compare the first action of each users list sending the outcome to each player. This process continues until the game concludes and the players are disconnected.
While I know that without the exact code and circumstances a definitive answer on how to achieve a large number of users will not be possible, but any suggestions would be appreciated.
Thanks,
Dan
Below is a breakdown of roughly how our game works.
Our game is broken into two separate components, a lobby server and game server(s).
The lobby server is a single room that's only job is to match users. As each user enters the lobby they are added to a thread safe list. A taskScheduler is set to run once a second and match up users with valid opponents. If a match is made then both clients are given the IP address of a game server and a unique room name. They then disconnect from the lobby server and connect to the game server. If no match is made they remain in the lobby until someone arrives that they can play against.
The game server has a zone level extension that handles the arrival of new users by adding them to a thread safe list and running a task periodically which creates new rooms for each pair of players that have arrived. The users are then moved into their rooms and the game begins.
Each game room holds two players and awaits actions from the players. These actions are stored in a pair of lists. A taskScheduler is set to run every 3 seconds and compare the first action of each users list sending the outcome to each player. This process continues until the game concludes and the players are disconnected.
While I know that without the exact code and circumstances a definitive answer on how to achieve a large number of users will not be possible, but any suggestions would be appreciated.
Thanks,
Dan