Trait StreamManager

Source
pub trait StreamManager: Send + Sync {
    // Required methods
    fn start<'life0, 'async_trait>(
        &'life0 self,
        ctl: StreamControl,
    ) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn next<'life0, 'async_trait>(
        &'life0 self,
        ctl: StreamControl,
    ) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn end<'life0, 'async_trait>(
        &'life0 self,
        ctl: StreamControl,
    ) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn stream_incoming(
        &self,
        id: StreamId,
    ) -> Pin<Box<dyn Stream<Item = Bytes> + Send>>;
}
Expand description

Streaming control plane to coordinate substreams or blob-backed flows.

Required Methods§

Source

fn start<'life0, 'async_trait>( &'life0 self, ctl: StreamControl, ) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source

fn next<'life0, 'async_trait>( &'life0 self, ctl: StreamControl, ) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source

fn end<'life0, 'async_trait>( &'life0 self, ctl: StreamControl, ) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Source

fn stream_incoming( &self, id: StreamId, ) -> Pin<Box<dyn Stream<Item = Bytes> + Send>>

Optional helper for control-plane streaming (chunked via frames).

Implementors§