Durable.DSL.Workflow (Durable v0.1.0-rc)

View Source

Provides the workflow macro for defining durable workflows.

Usage

defmodule MyApp.OrderWorkflow do
  use Durable

  workflow "process_order", timeout: hours(2) do
    step :validate do
      # ...
    end

    step :charge do
      # ...
    end
  end
end

Options

  • :timeout - Maximum workflow duration in milliseconds
  • :max_retries - Maximum retry attempts for the entire workflow
  • :queue - Default queue for this workflow

Summary

Functions

Defines a workflow with the given name and options.

Functions

workflow(name, opts \\ [], list)

(macro)

Defines a workflow with the given name and options.