Sha256: 7721c8da135f7ad97a5afd89c0b5de3363c210424415c38bf607e8195584f593

Contents?: true

Size: 787 Bytes

Versions: 19

Compression:

Stored size: 787 Bytes

Contents

module Dynflow
  module ExecutionPlan::Steps
    class FinalizeStep < AbstractFlowStep

      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

      def update_from_action(action)
        super
        self.progress_weight = action.finalize_progress_weight
      end

      def phase
        Action::Finalize
      end

      def mark_to_skip
        self.state = :skipped
        self.save
      end

    end
  end
end

Version data entries

19 entries across 19 versions & 1 rubygems

Version Path
dynflow-1.3.0 lib/dynflow/execution_plan/steps/finalize_step.rb
dynflow-1.2.3 lib/dynflow/execution_plan/steps/finalize_step.rb
dynflow-1.2.2 lib/dynflow/execution_plan/steps/finalize_step.rb
dynflow-1.2.1 lib/dynflow/execution_plan/steps/finalize_step.rb
dynflow-1.2.0 lib/dynflow/execution_plan/steps/finalize_step.rb
dynflow-1.2.0.pre1 lib/dynflow/execution_plan/steps/finalize_step.rb
dynflow-1.1.6 lib/dynflow/execution_plan/steps/finalize_step.rb
dynflow-1.1.5 lib/dynflow/execution_plan/steps/finalize_step.rb
dynflow-1.1.4 lib/dynflow/execution_plan/steps/finalize_step.rb
dynflow-1.1.3 lib/dynflow/execution_plan/steps/finalize_step.rb
dynflow-1.1.2 lib/dynflow/execution_plan/steps/finalize_step.rb
dynflow-1.1.1 lib/dynflow/execution_plan/steps/finalize_step.rb
dynflow-1.1.0 lib/dynflow/execution_plan/steps/finalize_step.rb
dynflow-1.0.5 lib/dynflow/execution_plan/steps/finalize_step.rb
dynflow-1.0.4 lib/dynflow/execution_plan/steps/finalize_step.rb
dynflow-1.0.3 lib/dynflow/execution_plan/steps/finalize_step.rb
dynflow-1.0.2 lib/dynflow/execution_plan/steps/finalize_step.rb
dynflow-1.0.1 lib/dynflow/execution_plan/steps/finalize_step.rb
dynflow-1.0.0 lib/dynflow/execution_plan/steps/finalize_step.rb