What does uniqueness mean in case of this gem? #30

Closed
kucaahbe opened this Issue Feb 17, 2014 · 2 comments

Comments

2 participants
@kucaahbe

I have a simple use-case:

  1. web server receives http request and schedules sidekiq job
  2. sidekiq job upon completion send http request (e.g. completion callback)

I want my sidekiq jobs to be unique during (for example) 2 hours. It means that after pushing some job with arguments {'a'=>1,'b'=>2} I do not want any other jobs with exactly same arguments to appear in queue and/or in "working" jobs regardless that first job state(successfully finished or failed). The result behavior that after first job finished I can add to queue other job with same arguments which is definitely not expected behavior (or am I missing something?).

So does it bug or feature?

Thanks!

@mhenrixon

This comment has been minimized.

Show comment Hide comment
@mhenrixon

mhenrixon Feb 19, 2014

Owner

It is explained in the readme. b77f6a5 so just set the unique_expiration = :timeout and the job won't be processed again until the timeout occurs. I will investigate a way to make this more obvious in the near future.

Owner

mhenrixon commented Feb 19, 2014

It is explained in the readme. b77f6a5 so just set the unique_expiration = :timeout and the job won't be processed again until the timeout occurs. I will investigate a way to make this more obvious in the near future.

@mhenrixon mhenrixon closed this Feb 19, 2014

@kucaahbe

This comment has been minimized.

Show comment Hide comment
@kucaahbe

kucaahbe Feb 19, 2014

got it, thank you!

got it, thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment