Class: Sidekiq::Tasks::Config
- Inherits:
-
Object
- Object
- Sidekiq::Tasks::Config
- Includes:
- Validations
- Defined in:
- lib/sidekiq/tasks/config.rb
Constant Summary collapse
- DEFAULT_SIDEKIQ_OPTIONS =
{ queue: "default", retry: false, }.freeze
- DEFAULT_STRATEGIES =
[ Sidekiq::Tasks::Strategies::RakeTask.new( rules: [ Sidekiq::Tasks::Strategies::Rules::TaskFromLib.new, Sidekiq::Tasks::Strategies::Rules::EnableWithComment.new, ] ), ].freeze
- DEFAULT_STORAGE =
Sidekiq::Tasks::Storage::Redis
- DEFAULT_HISTORY_LIMIT =
10
Instance Attribute Summary collapse
-
#authorization ⇒ Object
Returns the value of attribute authorization.
-
#current_user ⇒ Object
Returns the value of attribute current_user.
-
#history_limit ⇒ Object
Returns the value of attribute history_limit.
-
#sidekiq_options ⇒ Object
Returns the value of attribute sidekiq_options.
-
#storage ⇒ Object
Returns the value of attribute storage.
-
#strategies ⇒ Object
Returns the value of attribute strategies.
Instance Method Summary collapse
-
#initialize ⇒ Config
constructor
A new instance of Config.
Methods included from Validations
validate_array_classes!, validate_class!, validate_expected_values!, validate_hash_option!, validate_subclass!
Constructor Details
#initialize ⇒ Config
Returns a new instance of Config.
26 27 28 29 30 31 32 33 |
# File 'lib/sidekiq/tasks/config.rb', line 26 def initialize = DEFAULT_SIDEKIQ_OPTIONS @strategies = DEFAULT_STRATEGIES @storage = DEFAULT_STORAGE = ->(_env) { true } @history_limit = DEFAULT_HISTORY_LIMIT @current_user = nil end |
Instance Attribute Details
#authorization ⇒ Object
Returns the value of attribute authorization.
24 25 26 |
# File 'lib/sidekiq/tasks/config.rb', line 24 def end |
#current_user ⇒ Object
Returns the value of attribute current_user.
24 25 26 |
# File 'lib/sidekiq/tasks/config.rb', line 24 def current_user @current_user end |
#history_limit ⇒ Object
Returns the value of attribute history_limit.
24 25 26 |
# File 'lib/sidekiq/tasks/config.rb', line 24 def history_limit @history_limit end |
#sidekiq_options ⇒ Object
Returns the value of attribute sidekiq_options.
24 25 26 |
# File 'lib/sidekiq/tasks/config.rb', line 24 def end |
#storage ⇒ Object
Returns the value of attribute storage.
24 25 26 |
# File 'lib/sidekiq/tasks/config.rb', line 24 def storage @storage end |
#strategies ⇒ Object
Returns the value of attribute strategies.
24 25 26 |
# File 'lib/sidekiq/tasks/config.rb', line 24 def strategies @strategies end |