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

Don't perform logo search by default on logo search page #739

Closed
raphael0202 opened this issue Sep 5, 2023 · 0 comments · Fixed by #742
Closed

Don't perform logo search by default on logo search page #739

raphael0202 opened this issue Sep 5, 2023 · 0 comments · Fixed by #742
Labels

Comments

@raphael0202
Copy link
Contributor

raphael0202 commented Sep 5, 2023

On https://hunger.openfoodfacts.org/logos/search, the following HTTP request is sent automatically: https://robotoff.openfoodfacts.org/api/v1/images/logos/search/?count=25&random=true

This is a very heavy request for the DB, as , as we perform a double join over 2 tables to get the number of items without any filtering. It would be better not to send any request when the page load, and wait for the user to provide input.

@raphael0202 raphael0202 changed the title Don't perform random logo search on logo search page Don't perform logo search by default on logo search page Sep 5, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

1 participant