Crate archy Copy item path Source pub use tokio ;pub use async_channel ;pub use tracing ;prelude App Client Emit Event emitter - fire-and-forget broadcast to all subscribers. EventConfigBuilder Res ServiceConfigBuilder Shutdown ShutdownConfigBuilder Sub Event subscriber - receives events, skips missed if lagging. SystemConfigBuilder SystemDescriptor Descriptor for a registered system RestartPolicy Restart policy for service workers and systems when they panic Schedule Schedule determines when a system runs during the app lifecycle ServiceError Error returned when a service call fails SystemResult Result of system execution AddEvents AddResources AddServices ClientMethods Trait for generated client methods structs FromApp IntoSystem IntoSystemConfigs Trait for tuple system registration via add_systems Module Service ServiceFactory Helper trait generated by #[derive(Service)] - provides dependency injection ServiceFutureExt Adds .timeout(duration) to service calls. ServiceResultExt Adds .flatten_into::<AppError>() to flatten Result<Result<T,E>, ServiceError> into Result<T, AppError>.
Requires AppError: From<ServiceError> + From<E>. SystemOutput Trait for types that can be returned from system functions. SystemFactory A factory that can create system futures. Can be called multiple times (for Fixed schedules).
Uses Arc for zero-overhead sharing: dereference is same cost as Box, clone only on restart. service Attribute macro for Service impl blocks - generates message enum, Service impl, and Client methods shutdown Marker attribute for service shutdown hook.
Use on a single method within a #[service] impl block.
The method runs on shutdown, before channels close. startup Marker attribute for service startup hook.
Use on a single method within a #[service] impl block.
The method runs after service creation, before workers start receiving messages. traced Marker attribute to opt a method into span propagation.
Use on methods within a #[service] impl block. untraced Marker attribute to opt a method out of span propagation.
Use on methods within a #[service(traced)] impl block. Service Derive macro for Service structs - generates ServiceFactory implementation