Expand description
Transport routing for incoming system messages to native actor mailboxes. Transport routing for incoming system messages.
When a WireEnvelope arrives on a node, the transport layer must decide
whether it targets a user actor or a system actor. System messages carry
well-known message_type values (defined in
system_actors) and must be routed to the
corresponding system actor mailbox.
The SystemMessageRouter trait is implemented by each adapter runtime
to dispatch incoming system envelopes to native system actors.
§Example
ⓘ
let outcome = runtime.route_system_envelope(envelope).await?;
match outcome {
RoutingOutcome::SpawnCompleted { actor_id } => { /* ... */ }
RoutingOutcome::Acknowledged => { /* tell-style, no reply */ }
_ => {}
}Structs§
- Routing
Error - Error from system message routing.
Enums§
- Routing
Outcome - Result of successfully routing a system message.
Traits§
- System
Message Router - Routes incoming
WireEnvelopesystem messages to the correct native system actor mailbox.
Functions§
- validate_
system_ message_ type - Validates that an envelope carries a known system message type and returns an error if not. Useful for router implementations.