Struct kay::Networking[][src]

pub struct Networking {
    pub machine_id: MachineID,
    pub n_turns: usize,
    // some fields omitted
}

Represents all networking environment and networking state of an ActorSystem

Fields

The machine index of this machine within the network of peers

The current network turn this machine is in. Used to keep track if this machine lags behind or runs fast compared to its peers

Methods

impl Networking
[src]

Create network environment based on this machines id/index and all peer addresses (including this machine)

Try to connect to peers in the network

Finish the current networking turn and wait for peers which lag behind based on their turn number. This is the main backpressure mechanism.

Send queued outbound messages and take incoming queued messages and forward them to their local target recipient(s)

Enqueue a new (potentially) outbound packet

Return a debug message containing the current local view of network turn progress of all peers in the network

Auto Trait Implementations

impl Send for Networking

impl Sync for Networking