Class: Dynflow::ExecutionPlan::Steps::FinalizeStep
- Inherits:
-
AbstractFlowStep
- Object
- Serializable
- Abstract
- AbstractFlowStep
- Dynflow::ExecutionPlan::Steps::FinalizeStep
- Defined in:
- lib/dynflow/execution_plan/steps/finalize_step.rb
Instance Attribute Summary
Attributes inherited from Abstract
#action_class, #action_id, #ended_at, #error, #execution_plan_id, #execution_time, #id, #progress_weight, #real_time, #started_at, #state, #world
Attributes included from Stateful
Class Method Summary collapse
Instance Method Summary collapse
Methods inherited from AbstractFlowStep
Methods inherited from Abstract
#action, #action_logger, #cancellable?, #default_progress_done, #execute, #initialize, #persistence, #progress_done, #save, #skippable?, states, #to_hash, #to_s
Methods included from Stateful
included, #set_state, #state_transitions, #states
Methods inherited from Serializable
constantize, from_hash, new_from_hash, #to_hash
Constructor Details
This class inherits a constructor from Dynflow::ExecutionPlan::Steps::Abstract
Class Method Details
.state_transitions ⇒ Object
5 6 7 8 9 10 11 12 13 14 |
# File 'lib/dynflow/execution_plan/steps/finalize_step.rb', line 5 def self.state_transitions @state_transitions ||= { pending: [:running, :skipped], # :skipped when its run_step is skipped running: [:success, :error], success: [:pending], # when restarting finalize phase suspended: [], skipped: [], error: [:pending, :skipped] # pending when restarting finalize phase } end |
Instance Method Details
#mark_to_skip ⇒ Object
21 22 23 24 |
# File 'lib/dynflow/execution_plan/steps/finalize_step.rb', line 21 def mark_to_skip self.state = :skipped self.save end |
#phase ⇒ Object
17 18 19 |
# File 'lib/dynflow/execution_plan/steps/finalize_step.rb', line 17 def phase Action::Finalize end |