pub struct SubscribeConfig {
pub replay_from_slot: Option<i64>,
pub compression: Option<Compression>,
pub intra_slot_updates: bool,
}Expand description
Cross-cutting subscribe options the client sets in the config object.
Fields§
§replay_from_slot: Option<i64>Last slot the client already processed. On reconnect the server replays from this slot (inclusive) rather than streaming the full history.
compression: Option<Compression>Notification-frame compression the client opted into. None keeps the
uncompressed Text path.
intra_slot_updates: boolOne account notification per write. Absent/false is Agave parity: one per
account per slot, carrying the slot’s final state. Only accountSubscribe
and programSubscribe read it.
Implementations§
Source§impl SubscribeConfig
impl SubscribeConfig
Sourcepub fn from_value(config: Option<&Value>) -> Self
pub fn from_value(config: Option<&Value>) -> Self
Parse the cross-cutting options out of a subscribe config object. Per-kind fields are ignored, and a missing or malformed object yields defaults (all off), so a subscribe never fails on these optional fields.
Trait Implementations§
Source§impl Clone for SubscribeConfig
impl Clone for SubscribeConfig
Source§impl Debug for SubscribeConfig
impl Debug for SubscribeConfig
Source§impl Default for SubscribeConfig
impl Default for SubscribeConfig
Source§impl<'de> Deserialize<'de> for SubscribeConfig
impl<'de> Deserialize<'de> for SubscribeConfig
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for SubscribeConfig
Source§impl PartialEq for SubscribeConfig
impl PartialEq for SubscribeConfig
Source§impl Serialize for SubscribeConfig
impl Serialize for SubscribeConfig
impl StructuralPartialEq for SubscribeConfig
Auto Trait Implementations§
impl Freeze for SubscribeConfig
impl RefUnwindSafe for SubscribeConfig
impl Send for SubscribeConfig
impl Sync for SubscribeConfig
impl Unpin for SubscribeConfig
impl UnsafeUnpin for SubscribeConfig
impl UnwindSafe for SubscribeConfig
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