You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Due to the way matchmaking currently works, there is a bottleneck on scaling matchmaking and player signups:
If we have more than 1 createGame attempt at a time, we run into deadlocks as matchmaking tries to assign the same players to different games.
Due to locking for these deadlocks on the 'PlayerGame' index, actually inserting new players (CreatePlayer) suffers higher write latency.
To mitigate this, instead of assigning players to a game from ALL players ever, introduce a queue that simulates players 'getting ready to play'. This should reduce/remove lock contention on the PlayerGame index. We may still get deadlocks for concurrent CreateGame attempts, but it should be much smaller chance.
Design:
modify schema to allow for queue
modify matchmaking to assign players longest in the queue
keep track of average wait time in queue
game cannot be created if not enough players are in the queue.
game should not be created if players wait < average wait time. If there's not an average wait time, set a floor to prevent a flood of game creations.
The text was updated successfully, but these errors were encountered:
dtest
changed the title
Add player queueing
[Feature Request] Add player queueing
Oct 11, 2022
Due to the way matchmaking currently works, there is a bottleneck on scaling matchmaking and player signups:
To mitigate this, instead of assigning players to a game from ALL players ever, introduce a queue that simulates players 'getting ready to play'. This should reduce/remove lock contention on the PlayerGame index. We may still get deadlocks for concurrent CreateGame attempts, but it should be much smaller chance.
Design:
The text was updated successfully, but these errors were encountered: