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

max_run_time = 0 means something different to Delayed::Worker than it does to Delayed::Backend::ActiveRecord:: Job.ready_to_run #64

Open
gorism opened this issue Jun 6, 2013 · 0 comments

Comments

@gorism
Copy link

gorism commented Jun 6, 2013

Setting the Delayed::Worker.max_run_time to zero indicates that the Worker should not time out long running jobs. That is because it uses the Timeout library for managing timeout logic, and that is what zero means to that library.

However, the ready_to_run query doesn't special case that value, so it will end up selecting basically any job as "ready to run", because the conditional "OR locked_at < ?" (where ? = db_time_now - max_run_time) will almost always be true.

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

No branches or pull requests

1 participant