pub struct SessionOutputSender { /* private fields */ }Expand description
Cloneable producer for the byte-bounded session output queue.
Implementations§
Source§impl SessionOutputSender
impl SessionOutputSender
Sourcepub fn channel() -> (Self, Receiver<SessionOutputEnvelope>)
pub fn channel() -> (Self, Receiver<SessionOutputEnvelope>)
Create one ordered queue with a separate byte budget for data-bearing events.
Sourcepub fn split_channel() -> (Self, Receiver<SessionOutputEnvelope>, Receiver<SessionOutputEnvelope>, Receiver<BulkOutputCommand>)
pub fn split_channel() -> (Self, Receiver<SessionOutputEnvelope>, Receiver<SessionOutputEnvelope>, Receiver<BulkOutputCommand>)
Create independently bounded control and raw-bulk producer queues.
Sourcepub fn with_incarnation(&self, incarnation: Option<ClientIncarnation>) -> Self
pub fn with_incarnation(&self, incarnation: Option<ClientIncarnation>) -> Self
Scope future producer events to the client incarnation that opened their session.
Sourcepub fn disable_bulk_scheduler(&mut self)
pub fn disable_bulk_scheduler(&mut self)
Restore one ordered producer queue after boot selected combined mode.
Sourcepub fn drop_bulk_flow(
&self,
id: u32,
) -> Result<Option<Receiver<()>>, &'static str>
pub fn drop_bulk_flow( &self, id: u32, ) -> Result<Option<Receiver<()>>, &'static str>
Queue a high-priority purge for one operation without awaiting bulk-port progress.
Sourcepub fn drop_bulk_incarnation(
&self,
incarnation: ClientIncarnation,
) -> Result<Option<Receiver<()>>, &'static str>
pub fn drop_bulk_incarnation( &self, incarnation: ClientIncarnation, ) -> Result<Option<Receiver<()>>, &'static str>
Queue a high-priority purge for a disconnected range owner.
Sourcepub async fn send(&self, id: u32, output: SessionOutput) -> bool
pub async fn send(&self, id: u32, output: SessionOutput) -> bool
Queue an event after its retained allocation has acquired aggregate capacity.
Sourcepub async fn reserve(&self, max_bytes: usize) -> Option<SessionOutputPermit>
pub async fn reserve(&self, max_bytes: usize) -> Option<SessionOutputPermit>
Reserve capacity before reading or encoding up to max_bytes of output.
Sourcepub async fn reserve_bulk(
&self,
max_bytes: usize,
) -> Option<SessionOutputPermit>
pub async fn reserve_bulk( &self, max_bytes: usize, ) -> Option<SessionOutputPermit>
Reserve capacity from the raw-bulk budget before allocating a record payload.
Sourcepub async fn send_reserved(
&self,
id: u32,
output: SessionOutput,
permit: SessionOutputPermit,
) -> bool
pub async fn send_reserved( &self, id: u32, output: SessionOutput, permit: SessionOutputPermit, ) -> bool
Queue output using capacity obtained before the producer created its allocation.