Sha256: e3a2b00dffd30965a209923a5d8cbf7b35dc44a5ac087b605dd13039088081ec
Contents?: true
Size: 1.07 KB
Versions: 6
Compression:
Stored size: 1.07 KB
Contents
# frozen_string_literal: true require "active_support" require "sidekiq_publisher/version" require "sidekiq_publisher/instrumenter" require "sidekiq_publisher/metrics_reporter" require "sidekiq_publisher/exception_reporter" require "sidekiq_publisher/report_unpublished_count" require "sidekiq_publisher/job" require "sidekiq_publisher/worker" require "sidekiq_publisher/publisher" require "sidekiq_publisher/runner" require "sidekiq_publisher/railtie" if defined?(Rails) module SidekiqPublisher DEFAULT_BATCH_SIZE = 100 DEFAULT_JOB_RETENTION_PERIOD = 1.day.freeze class << self attr_accessor :logger, :exception_reporter, :metrics_reporter attr_writer :batch_size, :job_retention_period def configure yield self end def batch_size @batch_size || DEFAULT_BATCH_SIZE end def job_retention_period @job_retention_period || DEFAULT_JOB_RETENTION_PERIOD end # For test purposes def reset! @batch_size = nil @job_retention_period = nil @exception_reporter = nil @metrics_reporter = nil end end end
Version data entries
6 entries across 6 versions & 1 rubygems