Act.rs Version 0.3.0 Released
Act.rs 0.3.0 has been released with the following change notes:
Added
-
The tokio/entering module has been added which contains functions for dealing with entering runtime contexts.
-
Added impl_mac_task_actor_built_state, ActorStateBuilder and ActorStateBuilderAsync.
-
Added the Cargo.lock file.
-
Added get_input, get_input_with_err, get_input_with_errs, get_input_async, get_input_with_err_async and get_input_with_errs_async macros.
-
Added the std TwoPlusTwoActorState ThreadActor test to std/mod.
Changed
-
Updated the documentation of impl_mac_task_actor to reflect the fact that it no longer requires std::sync::Arc to be in module scope when used.
-
In tokio::BlockingActor, std::ThreadActor and tokio::TaskActor all struct level generic parameters and constraints have been removed. In each struct implementation all methods named “new” have been renamed to “spawn” with “ST” generic parameters added. The original generic constraint has been replaced with “ST: ActorStateAsync + Send + 'static” or “ST: ActorState + Send + 'static” for each method. Also the “run” methods in each struct implementation have had an identically named and constrained generic parameter added.
-
impl_mac_task_actor and its documentation has been changed to reflect TaskActor and the removal of the HasInteractor trait.
-
The renamed post_run and post_run_async methods are now run regardless of whether the (also renamed) pre_run or pre_run_async methods return true. This is the case for all actor implementations and meta-implementations.
-
impl_mac_task_actor now only takes the $actor_type parameter and derives the type name of the actor state from it. Its documentation has also been updated.
-
Constrained Self to Sized in ActorState.
-
Constrained Self to Sized in ActorStateAsync.
-
Renamed AsyncActorState to ActorStateAsync and updated the relevant parts of the project to reflect this change.
-
Made the inclusion of the async-trait dependency dependant on the presence of the tokio feature.
-
Made ActorStateAsync only be included if the tokio feature is enabled.
-
Renamed tokio sub-module macros impl_default_on_enter_async to impl_pre_run_async, impl_default_on_exit_async to impl_post_run_async and impl_default_on_enter_and_exit_async to impl_pre_and_post_run_async and made them compatible with ActorStateAsync.
-
The tokio minimum version has been updated to 1.44.2 and the async-trait minimum version has been updated to 0.1.88. Related dependencies have also been updated.
-
Updated the readme
-
Updated documentation
-
Disabled the test module in the lib file.
-
All methods named on_enter and on_exit have been renamed to pre_run and post_run and on_enter_async and on_exit_async have been renamed to pre_run_async and post_run_async respectively, whether they be in trait declarations, implementation blocks, macros or documentation.
-
Updated the MIT License copyright year.
Removed
-
Removed the Tokio runtime actors and macro.
-
Drop implementation blocks have been removed from the impl_mac_task_actor macro as well as all actor modules.
-
Removed the impl_not_dropped_on_enter_async and impl_not_dropped_on_enter_and_default_exit_async macros.
-
Removed the ActorInteractor and HasInteractor traits.
-
Removed the tokio/oneshot_at module.
-
Removed ActorFrontend
-
Removed DroppedDetector
-
Removed the impl_pub_sender, impl_new_sender, impl_interactor_clone, impl_actor_interactor and impl_actor_interactor_async macros.
-
Removed the interactors sub-module and it contents from std.
-
Removed the io sub-module and it contents from tokio.
-
Removed the futures and delegate dependencies.
-
Removed a rouge where keyword from the tokio/TaskActor implementaion.