Sha256: 00a0f785cc8fda2786e25d65a47c788f1012ff82cc2a005a1788f538ae59f2f3
Contents?: true
Size: 725 Bytes
Versions: 10
Compression:
Stored size: 725 Bytes
Contents
module Pageflow module ProcessedFileStateMachine extend ActiveSupport::Concern included do processing_state_machine do extend StateMachineJob::Macro state 'processing' state 'processed' state 'processing_failed' event :process do transition 'uploaded' => 'processing' transition 'processing_failed' => 'processing' end job ProcessFileJob do on_enter 'processing' result :ok => 'processed' result :error => 'processing_failed' end end end def retry! process! end def retryable? processing_failed? end def ready? processed? end end end
Version data entries
10 entries across 10 versions & 1 rubygems