Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cache beatmap listing search result #2828

Merged
merged 8 commits into from Mar 28, 2018

Conversation

3 participants
@notbakaneko
Copy link
Contributor

notbakaneko commented Mar 27, 2018

Quick fix to cache some of the results of the beatmap listing to reduce the queue size on elasticsearch.

@notbakaneko notbakaneko force-pushed the notbakaneko:hotfix/beatmaplist-result-cache branch from 09bff17 to 5e607ca Mar 27, 2018

private static function shouldCacheSearch(array $params)
{
return !(present($params['query']) || $params['recommended']);

This comment has been minimized.

@nanaya

nanaya Mar 27, 2018

Collaborator

also for status of 2 (favorites) and 6 (own maps) and rank (own ranked maps).

{
return !(
present($params['query'])
|| in_array($params['status'], [2, 6], true) // favourites, ranked.

This comment has been minimized.

@nanaya

nanaya Mar 27, 2018

Collaborator

More like 6 is own maps. Ranked is another parameter 💃

Accidentally commented in somewhere useless 👌

@nanaya

nanaya approved these changes Mar 28, 2018

@nanaya nanaya merged commit acd970f into ppy:master Mar 28, 2018

2 checks passed

continuous-integration/styleci/pr The analysis has passed
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details

@peppy peppy added the performance label Mar 29, 2018

@peppy peppy added this to the March 2018 milestone Mar 29, 2018

@notbakaneko notbakaneko deleted the notbakaneko:hotfix/beatmaplist-result-cache branch Apr 9, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.
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.