FAForever / server

The servercode for the Forged Alliance Forever lobby
http://www.faforever.com
GNU General Public License v3.0
67 stars 62 forks source link

Send estimated wait time when joining a queue #930

Open BlackYps opened 1 year ago

BlackYps commented 1 year ago

The server already logs the wait time of each search party. This data would need to be aggregated for rating brackets and sent to the client, which can then display it to the user. Challenges:

Implementation idea: We log the wait time together with total online players at that moment and the rating of the matched players. With some linear regressions we can then provide an estimate for a given rating and current number of online players

benjamin-lawson commented 6 months ago

I've opened a PR to add the player count of the queue as a dimension to the matchmaking search time metric in Prometheus. How does one take a look at these metrics for PROD?

BlackYps commented 6 months ago

You need to ask our server admins for access. But I am not sure how having this info in Prometheus is supposed to help? The wait time calculations need to happen in the server, so they can be sent to the clients

benjamin-lawson commented 6 months ago

You need to ask our server admins for access. But I am not sure how having this info in Prometheus is supposed to help? The wait time calculations need to happen in the server, so they can be sent to the clients

My idea was to add the dimension to prometheus to get initial regression modelling for the server calculations. We'd need a sufficiently large sample size for the linear regression so we can store it in prometheus to perform the regression. The other option is to store it in the DB for queue, # of players in the queue, and time it took to find a match.

BlackYps commented 6 months ago

I'd say it should be stored in the db otherwise it would be hard to get the info out of Prometheus again

benjamin-lawson commented 6 months ago

I'd say it should be stored in the db otherwise it would be hard to get the info out of Prometheus again

Okay too easy. I'll close that PR and get to work on that change.