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
Add scheduler to delete old notifications #6392
Comments
Can you try to run the query with |
It doesn't seem to affect the cost:
|
Can you try to just test the query? I think most of time is spent Updating rows and not finding them. |
I ran with EXPLAIN ANALYZE and the difference in execution time is huge:
Adding |
Thanks! Changed in 9ee1f7b |
Thanks! For me it's okay to close this issue since the root issue has been solved. |
Describe the current behavior
We've +5 millions rows in userNotification table and starting to see slow queries when marking notifications as read.
Steps to reproduce
No response
Describe the expected behavior
A scheduler should cleanup +4 weeks old, read notifications.
Additional information
PeerTube instance:
Browser name, version and platforms on which you could reproduce the bug:
Link to browser console log if relevant:
Link to server log if relevant (
journalctl
or/var/www/peertube/storage/logs/
):The text was updated successfully, but these errors were encountered: