Adventures in durable execution
summary
A Rails engine called Geneva Drive implements durable workflows as ActiveRecord records with per-step executions, using Active Job only as a trigger and cronable housekeeping; steps are run with DB locks, recorded for replay, and must be idempotent by design. It supports SQLite/MySQL/Postgres, an admin UI for pausing and resuming hung workflows, links to a polymorphic “hero” record for uniqueness, avoids external infra (Kafka/Redis/GRPC), and runs in production inside Cora and Porsche TUI.
AI-written summary · about
chapters (19)
- 0:00Introduction and speaker intro
- 1:06Who I am and my background
- 2:48What is a workflow?
- 5:16Problems with current workflow solutions
- 7:22DAGs in real-world systems
- 10:51Deception in imperative workflows
- 14:19Separating DAG and execution
- 16:46Geneva Drive workflow design
- 23:06Geneva Drive step execution
- 29:00How waiting and pausing works
- 32:31No extra systems needed
- 34:42Real-world applications
- 36:08Live demo of Geneva Drive
- 44:14Q&A: Conditional branches
- 45:59Q&A: Hero record relationship
- 47:26Q&A: Hero model mutations
- 49:14Q&A: When not to use workflows
- 51:00Q&A: Storing workflow state history
- 53:32Q&A: Scheduling precision
