pub struct PollConfig {
pub poll_interval: Duration,
pub empty_poll_backoff: Duration,
pub poll_failure_backoff: Duration,
pub max_consecutive_poll_failures: MaxConsecutiveFailures,
}Expand description
Configuration for projection polling behavior.
PollConfig controls how the projection runner polls for new events,
including intervals between polls and backoff strategies for empty results
or failures.
§Example
ⓘ
let config = PollConfig::default();
let runner = ProjectionRunner::new(projector, &store)
.with_poll_config(config);Fields§
§poll_interval: DurationInterval between polls when events are available.
empty_poll_backoff: DurationAdditional backoff delay when no events are found.
poll_failure_backoff: DurationAdditional backoff delay after a poll failure.
max_consecutive_poll_failures: MaxConsecutiveFailuresMaximum consecutive poll failures before stopping.
Trait Implementations§
Source§impl Clone for PollConfig
impl Clone for PollConfig
Source§fn clone(&self) -> PollConfig
fn clone(&self) -> PollConfig
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for PollConfig
impl Debug for PollConfig
Source§impl Default for PollConfig
impl Default for PollConfig
Source§impl PartialEq for PollConfig
impl PartialEq for PollConfig
impl Eq for PollConfig
impl StructuralPartialEq for PollConfig
Auto Trait Implementations§
impl Freeze for PollConfig
impl RefUnwindSafe for PollConfig
impl Send for PollConfig
impl Sync for PollConfig
impl Unpin for PollConfig
impl UnsafeUnpin for PollConfig
impl UnwindSafe for PollConfig
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