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

Fixed n+1 select problem #113

Merged
merged 4 commits into from
Dec 22, 2019
Merged

Fixed n+1 select problem #113

merged 4 commits into from
Dec 22, 2019

Conversation

maestrofjp
Copy link
Contributor

The original code called a get() in a loop which causes an n+1 select problem which is equal to the number of languages for the page. Fixed by reducing it to a single query.

@coveralls
Copy link

Coverage Status

Coverage remained the same at ?% when pulling eb304d4 on maestrofjp:develop into 249f5c1 on nephila:develop.

@coveralls
Copy link

coveralls commented Dec 19, 2019

Coverage Status

Coverage remained the same at ?% when pulling d75cc26 on maestrofjp:develop into 87ed135 on nephila:develop.

@yakky
Copy link
Member

yakky commented Dec 21, 2019

@maestrofjp thanks for the nice optimization!

I will fix tests on develop and then we can rebase this to a clean test run

@yakky
Copy link
Member

yakky commented Dec 22, 2019

@maestrofjp merging this, thanks a lot for your contribution

@yakky yakky merged commit 050bf2c into nephila:develop Dec 22, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants