#[non_exhaustive]pub enum SystemOp<C>where
C: ChannelKind,{
Show 13 variants
Auth {
client_id: Uuid,
token: Option<String>,
capabilities: Vec<C>,
resume_cursor: Option<u64>,
resume_cursors: HashMap<C, u64>,
},
AuthOk {
resume_cursor: u64,
resume_cursors: HashMap<C, u64>,
},
Error {
message: String,
},
Ping,
Pong,
Slow {
window: Option<u32>,
},
Ack {
channel: C,
cursor: u64,
},
ResumeRequired {
channel: C,
from_cursor: u64,
},
Subscribe {
channels: Vec<C>,
},
Unsubscribe {
channels: Vec<C>,
},
Health {
status: String,
detail: Option<String>,
},
Features {
supported: Vec<String>,
requested: Vec<String>,
},
Goodbye {
reason: Option<String>,
},
}Expand description
System control plane messages that travel on the system channel.
Parameterized by C: ChannelKind so that channel references in Auth,
Ack, Subscribe, etc. use the caller’s channel type.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Auth
Fields
AuthOk
Error
Ping
Pong
Slow
Ack
ResumeRequired
Subscribe
Unsubscribe
Health
Features
Goodbye
Implementations§
Trait Implementations§
Source§impl<'de, C> Deserialize<'de> for SystemOp<C>where
C: ChannelKind,
impl<'de, C> Deserialize<'de> for SystemOp<C>where
C: ChannelKind,
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<SystemOp<C>, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<SystemOp<C>, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl<C> Serialize for SystemOp<C>where
C: ChannelKind,
impl<C> Serialize for SystemOp<C>where
C: ChannelKind,
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
Auto Trait Implementations§
impl<C> Freeze for SystemOp<C>where
C: Freeze,
impl<C> RefUnwindSafe for SystemOp<C>where
C: RefUnwindSafe,
impl<C> Send for SystemOp<C>
impl<C> Sync for SystemOp<C>
impl<C> Unpin for SystemOp<C>where
C: Unpin,
impl<C> UnsafeUnpin for SystemOp<C>where
C: UnsafeUnpin,
impl<C> UnwindSafe for SystemOp<C>where
C: UnwindSafe,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more