Enum sn_routing::Event [−][src]
An Event raised by a Node
or Client
via its event sender.
These are sent by sn_routing to the library’s user. It allows the user to handle requests and responses, and to react to changes in the network.
Request
and Response
events from section locations are only raised once the majority has
been reached, i.e. enough members of the section have sent the same message.
Variants
Received a message.
Fields of MessageReceived
content: Bytes
The content of the message.
src: SrcLocation
The source location that sent the message.
dst: DstLocation
The destination location that receives the message.
proof_chain: Option<SectionChain>
The proof chain for the message, if any.
A new peer joined our section.
Fields of MemberJoined
A node left our section.
The set of elders in our section has changed.
Fields of EldersChanged
prefix: Prefix
The prefix of our section.
key: PublicKey
The BLS public key of our section.
sibling_key: Option<PublicKey>
The BLS public key of the sibling section, if this event is fired during a split.
Otherwise None
.
elders: BTreeSet<XorName>
The set of elders of our section.
self_status_change: NodeElderChange
Promoted, demoted or no change?
This node has started relocating to other section. Will be followed by
Relocated
when the node finishes joining the destination section.
Fields of RelocationStarted
previous_name: XorName
Previous name before relocation
This node has completed relocation to other section.
Fields of Relocated
Disconnected or failed to connect - restart required.
Received a message from a client node.
Fields of ClientMessageReceived
ClientLost(SocketAddr)
Failed in sending a message to client, or connection to client is lost
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for Event
impl Send for Event
impl Sync for Event
impl Unpin for Event
impl UnwindSafe for Event
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T> Instrument for T
[src]
pub fn instrument(self, span: Span) -> Instrumented<Self>
[src]
pub fn in_current_span(self) -> Instrumented<Self>
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> Same<T> for T
type Output = T
Should always be Self
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
pub fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,