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

Bugfix support overlap option #601

Open
wants to merge 6 commits into
base: master
Choose a base branch
from

Conversation

peret
Copy link

@peret peret commented Feb 27, 2017

Fixes #504 for recurring jobs. I'm not sure if the behavior should be the same for delayed jobs. Can be added easily, though.

Peter Retzlaff added 4 commits February 27, 2017 17:02
If overlap is set to false, we don't want to enqueue jobs if there's already one running or enqueued.
Add new method to get the queue_name and check if enqueuing is allowed.
end
return true if currently_processing

Resque.peek(queue_name, 0, 5000).any?
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Whats this jazz about?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Trying to figure out, if there's either a worker still working on the scheduled job or there's already one in the queue.
Granted, it's awkward. I updated the PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants