Introducing Theta, an async actor framework for Rust
https://github.com/cwahn/theta
Hey r/rust! 👋
I'm excited to share **Theta** - a new async actor framework I've been working on that aims to be ergonomic, minimal, and performant.
There are great actor frameworks out there, but I find some points to make them better especially regarding simplicity and remote support. Here are some of the key features.
- Async
- An actor instance is a very thin wrapper around a
tokio::taskand two MPSC channels. ActorRefis just a MPSC sender.
- An actor instance is a very thin wrapper around a
- Built-in remote
- Distributed actor system powered by P2P protocol,
iroh. - Even
ActorRefcould be passed around network boundary as regular data in message. - Available with feature
remote.
- Distributed actor system powered by P2P protocol,
- Built-in monitoring
- "Monitor" suggested by Carl Hewitt's Actor Model is implemented as (possibly remote) monitoring feature.
- Available with feature
monitor.
- Built-in persistence
- Seamless respawn of actor from snapshot on file system, AWS S3 etc.
- Available with feature
persistence.
- WASM support (WIP)
- Compile to WebAssembly for running in browser or other WASM environments
Just published v0.1.0-alpha.1 on crates.io!
Would love to hear your thoughts! What features would you want to see in an actor framework?
Links: