I taking some time to think better where to fit this framework. In it's current form it is built to write business logic, but at the same time it remains kind of a low level framework. I will research and see what are the next steps.
Acteur uses async_std
under the hood. You can find the all the information in the documentation.
This actor system is a bit different than other frameworks. It work under the following premises: - High-level: The framework is oriented to map business logic rather than concurrent tasks. - Simple: The API should be small, simple and intuitive. No surprises. - Fast: The system should be fast and use all available CPU cores. - Documented: Everything must be documented with exhaustive examples.
async_std
under the hood. (Even for mutexes)Acteur takes inspiration in Actors but it takes a different path. Actor based concurrency model is a concurrency modeling tool, not a business logic one, therefore, you cannot expect it to solve logic-organization problems with Actors. Still, Actors are a very nice abstraction that can, tangencially, solve certain nuances. Even more when the code scales.
In the way Acteur is implemented it searches to help you split your instances and keep request ordered and concurrent as much as possible between instances.
Said that, Acteur is provably not the tool you want if:
But it may help you if you want:
The overall feature set is complete. Acteur will continue improving and adding improvements. As for now, this framework is actively supported/developed.
The current focus is on ergonomics and use cases. Hopefully we can have an stable API soon.
Simple example
```rust use acteur::{Actor, Receive, Assistant, Acteur}; use asynctrait::asynctrait;
struct Employee { salary: u32 }
impl Actor for Employee {
type Id = u32;
async fn activate(_: Self::Id, _: &Assistant
struct SalaryChanged(u32);
impl Receive
fn main() { let sys = Acteur::new();
sys.sendtoactor_sync::
sys.waituntilstopped(); }
```
You can find more examples in the examples folder.
No unsafe code was directly used in this crate. You can check in lib.rs the #![deny(unsafe_code)]
line.
Licensed under either of Apache License, Version 2.0 or MIT license at your option.
Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in this crate by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.