vin
An ergonomic actor crate.
[]
= "2.1"
Overview
Vin's goal is to be an ergonomic actor library. The reason many actor libraries are so tedious to use is because they rely on a central System that needs to be shared among all actors. Vin ditches that burden by making every actor instance completely independent. Each actor gets its own task to poll messages and execute handlers on. Its address is shared by a simple Arc. Vin also provides a way to gracefully shutdown all actors without having to do the manual labour yourself. Actor data is stored in its actor context and is retrievable for reading with Actor::ctx() and for writing with Actor::ctx_mut() which acquire a RwLock to the data.
Vin completely relies on tokio (for the async runtime), tracing (for diagnostics), async_trait and anyhow (as the handler error type).
Example
Basic usage of vin.
use Duration;
use Level;
use *;
async
License
This project is licensed under the MIT license.