โฑ๏ธ Temporal Flashcards
Durable execution platform for reliable, long-running workflows
๐ก What is Temporal?
A platform for writing fault-tolerant workflows in code. It guarantees state, retries, and progress despite failures.
๐ง Core Concepts
Workflows (orchestration, deterministic) and Activities (side effects, I/O) with strong durability guarantees.
๐ Retries & Timeouts
Built-in, policy-driven retries with exponential backoff, per-activity timeouts, and failure handling.
๐งต Deterministic Workflows
Workflow code must be deterministic; the Temporal server replays event history to reconstruct state.
๐งฉ Task Queues
Workflows dispatch Activities to worker processes via task queues for horizontal scalability and isolation.
๐งท Signals & Queries
Signals push external events into running workflows; Queries read workflow state consistently.
โฐ Timers & Cron
Schedule timers, sleeps, and periodic executions with cron-like schedules inside workflows.
๐งช Testing
Deterministic, fast unit tests with a test workflow environment; mock Activities and time travel.
๐ Reliability Model
At-least-once Activity execution, exactly-once workflow progression via event sourcing and idempotency.
๐ Multi-Language SDKs
Official SDKs for TypeScript, Go, Java, Python (emerging), and community ports for other languages.
๐๏ธ Use Cases
Sagas & transactions, payment orchestration, media processing, ML pipelines, email/drip campaigns, backfills, and agents.
๐ Deployment Options
Self-host on Kubernetes, run via Temporal Cloud (managed), or hybrid; observability via Web UI & metrics.