1 unstable release
0.0.1 | Jan 19, 2020 |
---|
#6 in #scrappy
Used in 2 crates
435KB
10K
SLoC
scrappy_actor is a rust actors framework
Actors are
objects which encapsulate state and behavior, they communicate
exclusively by exchanging messages. scrappy_actor actors are implemented
on top of Tokio. Multiple actors can run in
same thread. Actors can run in multiple threads using the
Arbiter
API. Actors exchange typed
messages.
Documentation
- User Guide
- Chat on gitter
- GitHub repository
- Cargo package
- Minimum supported Rust version: 1.39 or later
Features
- Async/Sync actors.
- Actor communication in a local/thread context.
- Using Futures for asynchronous message handling.
- HTTP1/HTTP2 support (scrappy_actor-web)
- Actor supervision.
- Typed messages (No
Any
type). Generic messages are allowed.
Package feature
resolver
- enables dns resolver actor,scrappy_actor::actors::resolver
Tokio runtime
At the moment scrappy_actor uses
current_thread
runtime.
While it provides minimum overhead, it has its own limits:
- You cannot use tokio's async file I/O, as it relies on blocking calls that are not available
in
current_thread
Stdin
,Stderr
andStdout
fromtokio::io
are the same as file I/O in that regard and cannot be used in asynchronous manner in scrappy_actor. Thescrappy_actor
prelude.
The purpose of this module is to alleviate imports of many common scrappy_actor traits by adding a glob import to the top of scrappy_actor heavy modules:
use scrappy_actor::prelude::*;
The scrappy_actor
prelude for library developers.
The purpose of this module is to alleviate imports of many common scrappy_actor traits by adding a glob import to the top of scrappy_actor heavy modules:
use scrappy_actor::dev::*;
Dependencies
~7–11MB
~210K SLoC