-
-
Notifications
You must be signed in to change notification settings - Fork 199
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
Cleaning up preserved jobs giving me timeout #933
Comments
@murparreira nuts! Can you tell me what your query timeout is? I have a PR that I think might help. Would you be willing to try running that? #934 |
I like the loop. I think that will result in one less query than using Active Record's in_batches. |
This PR #934, when merged fixes this problem. |
@murparreira thank you for reporting this and the help fixing it! I released the change: https://github.com/bensheldon/good_job/releases/tag/v3.15.2 |
No problem! Happy to help. |
Hey guys, thanks for the wonderful gem.
I am getting a timeout on my postgresql database when i run a task for deleting preserved jobs.
Right now we have more than 500k jobs succeeded.
This is the code inside the task.
GoodJob.cleanup_preserved_jobs(older_than: 1.days)
Can anyone point me in the right direction here?
The text was updated successfully, but these errors were encountered: