pub struct MemorySubscriber { /* private fields */ }Implementations§
Source§impl MemorySubscriber
impl MemorySubscriber
pub fn new(config: &MemoryConfig, id: &str) -> Result<Self>
Trait Implementations§
Source§impl MessageConsumer for MemorySubscriber
impl MessageConsumer for MemorySubscriber
Source§fn receive_batch<'life0, 'async_trait>(
&'life0 mut self,
max_messages: usize,
) -> Pin<Box<dyn Future<Output = Result<ReceivedBatch, ConsumerError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn receive_batch<'life0, 'async_trait>(
&'life0 mut self,
max_messages: usize,
) -> Pin<Box<dyn Future<Output = Result<ReceivedBatch, ConsumerError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Receives a batch of messages. Read more
Source§fn receive<'life0, 'async_trait>(
&'life0 mut self,
) -> Pin<Box<dyn Future<Output = Result<Received, ConsumerError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn receive<'life0, 'async_trait>(
&'life0 mut self,
) -> Pin<Box<dyn Future<Output = Result<Received, ConsumerError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Receives a single message.
fn as_any(&self) -> &dyn Any
Source§fn on_connect_hook(&self) -> Option<BoxFuture<'_, Result<()>>>
fn on_connect_hook(&self) -> Option<BoxFuture<'_, Result<()>>>
Returns an optional lifecycle hook that runs once after the consumer connection is created. Read more
Source§fn on_disconnect_hook(&self) -> Option<BoxFuture<'_, Result<()>>>
fn on_disconnect_hook(&self) -> Option<BoxFuture<'_, Result<()>>>
Returns an optional lifecycle hook that runs before the consumer is dropped. Read more
fn receive_batch_helper<'life0, 'async_trait>(
&'life0 mut self,
_max_messages: usize,
) -> Pin<Box<dyn Future<Output = Result<ReceivedBatch, ConsumerError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn status<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = EndpointStatus> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Auto Trait Implementations§
impl !RefUnwindSafe for MemorySubscriber
impl !Unpin for MemorySubscriber
impl !UnsafeUnpin for MemorySubscriber
impl !UnwindSafe for MemorySubscriber
impl Freeze for MemorySubscriber
impl Send for MemorySubscriber
impl Sync for MemorySubscriber
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