Class: RubyReactor::Dsl::InterruptStepConfig
- Inherits:
-
StepConfig
- Object
- StepConfig
- RubyReactor::Dsl::InterruptStepConfig
- Defined in:
- lib/ruby_reactor/dsl/interrupt_step_config.rb
Instance Attribute Summary collapse
-
#correlation_id_block ⇒ Object
readonly
Returns the value of attribute correlation_id_block.
-
#max_attempts ⇒ Object
readonly
Returns the value of attribute max_attempts.
-
#resume_mode ⇒ Object
readonly
Returns the value of attribute resume_mode.
-
#strategy ⇒ Object
readonly
Returns the value of attribute strategy.
-
#timeout_config ⇒ Object
readonly
Returns the value of attribute timeout_config.
-
#validation_schema ⇒ Object
readonly
Returns the value of attribute validation_schema.
Attributes inherited from StepConfig
#args_validator, #arguments, #async_dispatch, #compensate_block, #conditions, #dependencies, #guards, #impl, #name, #output_validator, #retry_config, #run_block, #undo_block
Instance Method Summary collapse
- #background_resume? ⇒ Boolean
-
#initialize(config) ⇒ InterruptStepConfig
constructor
A new instance of InterruptStepConfig.
- #interrupt? ⇒ Boolean
Methods inherited from StepConfig
#async_dispatch?, #has_impl?, #has_run_block?, #retryable?, #should_run?
Constructor Details
#initialize(config) ⇒ InterruptStepConfig
Returns a new instance of InterruptStepConfig.
9 10 11 12 13 14 15 16 |
# File 'lib/ruby_reactor/dsl/interrupt_step_config.rb', line 9 def initialize(config) super @correlation_id_block = config[:correlation_id_block] @timeout_config = config[:timeout_config] @validation_schema = config[:validation_schema] @max_attempts = config[:max_attempts] || 1 @resume_mode = config[:resume_mode] || :inline end |
Instance Attribute Details
#correlation_id_block ⇒ Object (readonly)
Returns the value of attribute correlation_id_block.
6 7 8 |
# File 'lib/ruby_reactor/dsl/interrupt_step_config.rb', line 6 def correlation_id_block @correlation_id_block end |
#max_attempts ⇒ Object (readonly)
Returns the value of attribute max_attempts.
6 7 8 |
# File 'lib/ruby_reactor/dsl/interrupt_step_config.rb', line 6 def max_attempts @max_attempts end |
#resume_mode ⇒ Object (readonly)
Returns the value of attribute resume_mode.
6 7 8 |
# File 'lib/ruby_reactor/dsl/interrupt_step_config.rb', line 6 def resume_mode @resume_mode end |
#strategy ⇒ Object (readonly)
Returns the value of attribute strategy.
6 7 8 |
# File 'lib/ruby_reactor/dsl/interrupt_step_config.rb', line 6 def strategy @strategy end |
#timeout_config ⇒ Object (readonly)
Returns the value of attribute timeout_config.
6 7 8 |
# File 'lib/ruby_reactor/dsl/interrupt_step_config.rb', line 6 def timeout_config @timeout_config end |
#validation_schema ⇒ Object (readonly)
Returns the value of attribute validation_schema.
6 7 8 |
# File 'lib/ruby_reactor/dsl/interrupt_step_config.rb', line 6 def validation_schema @validation_schema end |
Instance Method Details
#background_resume? ⇒ Boolean
22 23 24 |
# File 'lib/ruby_reactor/dsl/interrupt_step_config.rb', line 22 def background_resume? @resume_mode == :background end |
#interrupt? ⇒ Boolean
18 19 20 |
# File 'lib/ruby_reactor/dsl/interrupt_step_config.rb', line 18 def interrupt? true end |