debit is a read-modify-write with no lock and no transaction. In a normal request
handler that’s a race; here it isn’t — and that property is the whole product.
How it works derives it from
first principles, starting from a plain C server.
Two words used precisely throughout these docs: the actor is the class you ship
(Account); an instance is its per-name materialization (idFromName("acct_123")
reaches the acct_123 instance of Account).
What the Runtime Guarantees
- One instance per name —
idFromName("acct_123")routes every call to a single owner; no two hosts run it at once. - One call at a time — single-threaded dispatch. No locks, no races inside an instance.
- Durable before reply — a method’s result isn’t returned until the writes it made are persisted.
- Memory is a cache — only what you write to
storagesurvives eviction or restart.
Quick start
Scaffold, deploy, and curl an actor.
How it works
The C-vs-actor derivation from first principles.
Execution model
The four guarantees, stated precisely.
Lifecycle & placement
Where instances run; what survives a restart.
Addressing
Naming and routing instances.
Project structure
The two-export shape.
Shared actors
Reach one actor from many functions.
When to use
And when to reach for something else.
Runtime API
The full surface.
Alarms
Scheduled work from inside an actor.
Related Resources
- Bindings — how bindings resolve on
env - KV — globally distributed key-value storage
- Execution Model — function lifecycle and concurrency