Movie¶
Movie is a lightweight typed actor framework for Crystal. It combines actor lifecycle and supervision, ask/futures, bounded execution, typed streams, pluggable persistence, restart-tolerant remoting, and cluster extensions in one coherent runtime.
Browse the Crystal API reference
Start here¶
- New to Movie? Begin with actor lifecycle and supervision.
- Building stateful actors? Read the persistence guide.
- Connecting processes? Start with remoting, then cluster membership.
- Distributing logical entities? Compare sharding, singletons, service discovery, and cluster routers.
- Building bounded pipelines? See the typed streams guide.
Minimal actor¶
require "movie"
class Printer < Movie::AbstractBehavior(String)
def receive(message : String, context : Movie::ActorContext(String))
puts message
Movie::Behaviors(String).same
end
end
system = Movie::ActorSystem(Nil).new(Movie::Behaviors(Nil).same)
printer = system.spawn(Printer.new, name: "printer")
printer << "hello from Movie"
system.shutdown
Movie requires Crystal 1.19.1 through 1.21.x. Add the shard and install it:
dependencies:
movie:
github: mikeoz32/movie
shards install
Maturity at a glance¶
| Area | Status |
|---|---|
| Typed actors, lifecycle, ask, futures, scheduler | Stable public API |
| Persistence and remoting | Production beta |
| Cluster membership, sharding, singleton, receptionist, routers | Production alpha |
| Typed streams | MVP |
The labels describe API and operational maturity, not marketing stability. Each guide documents its delivery guarantees and known limitations.
Two documentation surfaces¶
This MkDocs site contains architecture, operational contracts, examples, and decision guidance maintained as Markdown. The separate Crystal API reference is generated from public source declarations and their canonical doc comments on every deployment.