Enum ockam_node::NodeMessage [−][src]
pub enum NodeMessage {
StartWorker(AddressSet, Sender<RelayMessage>, Sender<NodeReplyResult>),
ListWorkers(Sender<NodeReplyResult>),
StopWorker(Address, Sender<NodeReplyResult>),
StartProcessor(Address, Sender<RelayMessage>, Sender<NodeReplyResult>, ShutdownHandle),
StopProcessor(Address, Sender<NodeReplyResult>),
StopNode,
SenderReq(Address, Sender<NodeReplyResult>),
Router(u8, Address, Sender<NodeReplyResult>),
CheckAddress(AddressSet, Sender<NodeReplyResult>),
}
Expand description
Messages sent from the Node to the Executor
Variants
StartWorker(AddressSet, Sender<RelayMessage>, Sender<NodeReplyResult>)
Start a new worker and store the send handle
Tuple Fields of StartWorker
ListWorkers(Sender<NodeReplyResult>)
Return a list of all worker addresses
Tuple Fields of ListWorkers
StopWorker(Address, Sender<NodeReplyResult>)
Stop an existing worker
Tuple Fields of StopWorker
0: Address
1: Sender<NodeReplyResult>
StartProcessor(Address, Sender<RelayMessage>, Sender<NodeReplyResult>, ShutdownHandle)
Start a new processor and store the send and shutdown handles
Tuple Fields of StartProcessor
StopProcessor(Address, Sender<NodeReplyResult>)
Stop an existing processor
Tuple Fields of StopProcessor
0: Address
1: Sender<NodeReplyResult>
Stop the node (and all workers)
SenderReq(Address, Sender<NodeReplyResult>)
Request the sender for a worker address
Tuple Fields of SenderReq
0: Address
1: Sender<NodeReplyResult>
Router(u8, Address, Sender<NodeReplyResult>)
Register a new router for a route id type
Tuple Fields of Router
CheckAddress(AddressSet, Sender<NodeReplyResult>)
Check if a given address is already registered
Tuple Fields of CheckAddress
0: AddressSet
1: Sender<NodeReplyResult>
Implementations
pub fn start_worker(
address: AddressSet,
sender: Sender<RelayMessage>
) -> (Self, Receiver<NodeReplyResult>)
pub fn start_worker(
address: AddressSet,
sender: Sender<RelayMessage>
) -> (Self, Receiver<NodeReplyResult>)
Create a start worker message
pub fn start_processor(
address: Address,
sender: Sender<RelayMessage>,
shutdown_handle: ShutdownHandle
) -> (Self, Receiver<NodeReplyResult>)
pub fn start_processor(
address: Address,
sender: Sender<RelayMessage>,
shutdown_handle: ShutdownHandle
) -> (Self, Receiver<NodeReplyResult>)
Create a start worker message
Create a stop worker message and reply receiver
Create a list worker message and reply receiver
Create a stop worker message and reply receiver
Create a sender request message and reply receiver
Create a message to check the availability of an address set
Trait Implementations
Auto Trait Implementations
impl !RefUnwindSafe for NodeMessage
impl Send for NodeMessage
impl Sync for NodeMessage
impl Unpin for NodeMessage
impl !UnwindSafe for NodeMessage
Blanket Implementations
Mutably borrows from an owned value. Read more
pub fn vzip(self) -> V
Attaches the provided Subscriber
to this type, returning a
WithDispatch
wrapper. Read more
Attaches the current default Subscriber
to this type, returning a
WithDispatch
wrapper. Read more