pub struct LoggingHandler { /* private fields */ }Expand description
A handler that logs all events for debugging
Implementations§
Trait Implementations§
Source§impl<E: DomainEvent> EventHandler<E> for LoggingHandler
impl<E: DomainEvent> EventHandler<E> for LoggingHandler
Source§fn handle<'life0, 'async_trait>(
&'life0 self,
envelope: EventEnvelope<E>,
) -> Pin<Box<dyn Future<Output = Result<(), EventError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn handle<'life0, 'async_trait>(
&'life0 self,
envelope: EventEnvelope<E>,
) -> Pin<Box<dyn Future<Output = Result<(), EventError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Handle a domain event Read more
Source§fn event_types(&self) -> Vec<&'static str>
fn event_types(&self) -> Vec<&'static str>
Event types this handler is interested in Read more
Source§fn should_retry(&self) -> bool
fn should_retry(&self) -> bool
Whether this handler should be retried on failure
Source§fn max_retries(&self) -> u32
fn max_retries(&self) -> u32
Maximum retry attempts
Auto Trait Implementations§
impl Freeze for LoggingHandler
impl RefUnwindSafe for LoggingHandler
impl Send for LoggingHandler
impl Sync for LoggingHandler
impl Unpin for LoggingHandler
impl UnsafeUnpin for LoggingHandler
impl UnwindSafe for LoggingHandler
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