I would like to enforce uniqueness of a sidekiq job using sidekiq unique jobs and activejob. On the documentation for sidekiq unique jobs it says
Usage with ActiveJob
Sidekiq.default_worker_options = {
unique: :until_executing,
unique_args: ->(args) { [ args.first.except('job_id') ] }
}
Which is totally non-descriptive. Which file does this go in, and how do I attach these options to a job if I want to set the options on a per-job basis? How do I modify the job? An example of how to use this with activejob would be much appreciated as the documentation is not understandable.
It seems like ActiveJob is not supported in latest version.
One can use https://github.com/veeqo/activejob-uniqueness