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

Confused with UntilExecuted documenation #326

Closed
ivanovaleksey opened this issue Aug 18, 2018 · 1 comment
Closed

Confused with UntilExecuted documenation #326

ivanovaleksey opened this issue Aug 18, 2018 · 1 comment

Comments

@ivanovaleksey
Copy link

Hello, thank you for the awesome library!

I am going to use it in a project to ensure a uniqueness for slow & long running jobs.
While choosing a proper lock type for my case I noticed that documentation for UntilExecuted and UntilExecuting about unlocks seems to be the same though as I can see it should be slightly different.

https://github.com/mhenrixon/sidekiq-unique-jobs/blob/master/lib/sidekiq_unique_jobs/lock/until_executed.rb#L7
https://github.com/mhenrixon/sidekiq-unique-jobs/blob/master/lib/sidekiq_unique_jobs/lock/until_executing.rb#L7

As I understand UntilExecuted should unlock after worker done it's job. It is also stated here.
Please correct me if I am missing something.

@mhenrixon
Copy link
Owner

Sorry about that, looks like a sloppy paste @ivanovaleksey. I'll get it fixed, the until executing does indeed unlock before yielding to the worker.

I'm really happy that someone is reading the documentation though :) Means the effort of writing it wasn't all a waste.

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

2 participants