Class: CacheKeeper::Configuration

Inherits:
Object
  • Object
show all
Defined in:
lib/cache_keeper/configuration.rb

Constant Summary collapse

DEFAULT_MUST_REVALIDATE =
false
DEFAULT_QUEUES =
{}.freeze
DEFAULT_ACTIVE_JOB_PARENT_CLASS =
"ActiveJob::Base".freeze

Instance Method Summary collapse

Instance Method Details

#active_job_parent_classObject



17
18
19
# File 'lib/cache_keeper/configuration.rb', line 17

def active_job_parent_class
  rails_config.active_job_parent_class || DEFAULT_ACTIVE_JOB_PARENT_CLASS
end

#must_revalidateObject



7
8
9
10
11
# File 'lib/cache_keeper/configuration.rb', line 7

def must_revalidate
  return rails_config.must_revalidate unless rails_config.must_revalidate.nil?

  DEFAULT_MUST_REVALIDATE
end

#queuesObject



13
14
15
# File 'lib/cache_keeper/configuration.rb', line 13

def queues
  rails_config.queues || DEFAULT_QUEUES
end