Skip to content

while_executing working wrong #193

@hiennguyenvan-agilityio

Description

As description, it is to make sure that a job can be scheduled any number of times but only executed a single time per argument provided to the job we call this runtime uniqueness. But it not work for me

class Job
  include Sidekiq::Worker
  sidekiq_options queue: :test, retry: true, unique: :while_executing

  def perform(arg)
    sleep 5.minutes
  end
end

Job.perform_async(1)
Job.perform_async(1)
Job.perform_async(2)

Have two Job with arg is 1 execute at the time

screen shot 2016-08-29 at 17 31 24

System information

Sidekiq Config

:queues:
  - test
  - default
:limits:
  test: 3

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions