Skip to content

v0.1.0

Choose a tag to compare

@JustSteveKing JustSteveKing released this 24 Jul 09:58
· 17 commits to main since this release

The first release of the workflow engine. Model long-running, multi-step Laravel processes as an ordered list of steps that complete, await a named signal, sleep, branch via goto, or fail. Instances are persisted as rows, driven forward by queued jobs, and resumed by signals from the outside world.

Install

composer require juststeveking/workflow-engine

Requires PHP 8.5 and Laravel 13.

What's included

  • Step outcomes: complete, await, goto (branching), sleep (delays), fail
  • Per-step timeouts tagged to the guarded step, and bounded retries with configurable exponential backoff (HasRetryBackoff)
  • Saga compensation via CompensatingStep (run outside the lock, with a StepCompensationFailed event), early-signal buffering, and definition versioning
  • Status lifecycle enforced through juststeveking/state-machine — illegal transitions throw
  • Domain events for every transition
  • Row locking and after-commit dispatch for at-least-once queue safety
  • Swappable persistence behind WorkflowRepositoryContract
  • Nine artisan commands: list, show, instances, start, signal, advance, retry, tick, prune
  • Full Unit + Feature suite, PHPStan level 10, Pint, CI, and four worked examples

See the README and the examples.