Skip to content

User most played maps is really slow to the point of timeouts #180

Description

@AiAe

Most noticeable for players with a lot of scores.
I'm not too sure how we can resolve this so far without database structure changes.
But hitting the scores table + joining map to check for ranking status is pretty much looping all their scores.

Best solution would be dedicated table for the counts per map for the user where we just increment.

user_map_play_counts:
user_id
map_id (or md5?)
play_count

user_id & map_id primary
index user_id, play count DESC, map_id

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions