Sha256: c303279ffd1e02008bf9e96f6cb089d640763a6843055a854423501354baccc1

Contents?: true

Size: 218 Bytes

Versions: 3

Compression:

Stored size: 218 Bytes

Contents

class ProcPeriodWorker
  include Sidekiq::Worker

  sidekiq_options throttle: { threshold: 10, period: Proc.new { |user_id, period| period } }

  def perform(user_id, period)
    puts user_id
    puts period
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
sidekiq-throttler-0.5.1 spec/app/workers/proc_period_worker.rb
sidekiq-throttler-0.4.1 spec/app/workers/proc_period_worker.rb
sidekiq-throttler-0.4.0 spec/app/workers/proc_period_worker.rb