pub struct MultiplexedPollerBuilder { /* private fields */ }Expand description
Accumulates Routes and builds a MultiplexedPoller.
Implementations§
Source§impl MultiplexedPollerBuilder
impl MultiplexedPollerBuilder
Sourcepub fn new(head: Arc<dyn HeadSource>, poll_interval: Duration) -> Self
pub fn new(head: Arc<dyn HeadSource>, poll_interval: Duration) -> Self
Construct with the defaults every route shares: the deploy floor (0),
DEFAULT_GET_LOGS_MAX_BLOCK_SPAN, and the default watcher backoff
schedule.
Sourcepub const fn max_backfill_span(self, span: u64) -> Self
pub const fn max_backfill_span(self, span: u64) -> Self
Set the block-span ceiling per eth_getLogs window
(blockchain.get_logs_max_block_span). The poller starts there,
shrinks below it on a provider range rejection and regrows back to it.
Self::build rejects 0.
Sourcepub fn build(self) -> Result<MultiplexedPoller>
pub fn build(self) -> Result<MultiplexedPoller>
Build the poller: construct the merged filter and the (address, topic0) -> route demux index. Returns Err if two routes claim the
same (address, topic0) key — two watchers subscribing to the same
event is a wiring bug, not a runtime condition, so it fails fast at
startup rather than silently routing every such log to whichever route
happened to register first.
Trait Implementations§
Auto Trait Implementations§
impl !RefUnwindSafe for MultiplexedPollerBuilder
impl !Sync for MultiplexedPollerBuilder
impl !UnwindSafe for MultiplexedPollerBuilder
impl Freeze for MultiplexedPollerBuilder
impl Send for MultiplexedPollerBuilder
impl Unpin for MultiplexedPollerBuilder
impl UnsafeUnpin for MultiplexedPollerBuilder
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
Source§impl<T> FutureExt for T
impl<T> FutureExt for T
Source§fn with_context(self, otel_cx: Context) -> WithContext<Self> ⓘ
fn with_context(self, otel_cx: Context) -> WithContext<Self> ⓘ
Source§fn with_current_context(self) -> WithContext<Self> ⓘ
fn with_current_context(self) -> WithContext<Self> ⓘ
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::Request