pub struct FileConsumer { /* private fields */ }Expand description
A consumer that reads messages from a file and removes them upon commit.
Implementations§
Source§impl FileConsumer
impl FileConsumer
Trait Implementations§
Source§impl MessageConsumer for FileConsumer
impl MessageConsumer for FileConsumer
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
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
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 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 FileConsumer
impl !Unpin for FileConsumer
impl !UnsafeUnpin for FileConsumer
impl !UnwindSafe for FileConsumer
impl Freeze for FileConsumer
impl Send for FileConsumer
impl Sync for FileConsumer
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