Sha256: 4a41005ff5dd657ec82ca1910ad2081fac7aa2623ca048b0b1b1b7a37420582c

Contents?: true

Size: 618 Bytes

Versions: 2

Compression:

Stored size: 618 Bytes

Contents

# rubocop:disable FileName
require 'yaml' if RUBY_VERSION.include?('2.0.0')
require 'sidekiq_unique_jobs/middleware'
require 'sidekiq_unique_jobs/version'
require 'sidekiq_unique_jobs/config'
require 'sidekiq_unique_jobs/payload_helper'
require 'ostruct'

module SidekiqUniqueJobs
  module_function

  def config
    @config ||= Config.new(
      unique_prefix: 'sidekiq_unique',
      unique_args_enabled: false,
      default_expiration: 30 * 60,
      default_unlock_order: :after_yield
    )
  end

  def unique_args_enabled?
    config.unique_args_enabled
  end

  def configure
    yield configuration
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
sidekiq-unique-jobs-3.0.8 lib/sidekiq-unique-jobs.rb
sidekiq-unique-jobs-3.0.7 lib/sidekiq-unique-jobs.rb