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

optimise slow queries #63

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

NtTestAlert
Copy link

The queries were slow
first one used full table scan, while it can take advantage of index on flags
second one scanned also those rows which were already active=0

@ghost
Copy link

ghost commented Dec 16, 2019

The 2nd query is a killer. I had 5 millions peers on the peers table and everytime that query ran it hanged the tracker for 5-10 seconds...it should be corrected.

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.

1 participant