pub struct ReplayContext {
pub is_replay: bool,
pub reorg_from_block: Option<u64>,
pub original_block_hash: Option<String>,
}Expand description
Context about whether the current execution is a reorg replay.
Passed to handlers so they can adjust their behavior during replay. For example, handlers should skip sending webhooks or notifications during replay, but still update local entity state.
Fields§
§is_replay: booltrue if the indexer is replaying blocks after a reorg.
reorg_from_block: Option<u64>The block number where the reorg was detected (fork point).
None if this is not a replay.
original_block_hash: Option<String>The original block hash that was replaced by the reorg.
None if this is not a replay.
Implementations§
Trait Implementations§
Source§impl Clone for ReplayContext
impl Clone for ReplayContext
Source§fn clone(&self) -> ReplayContext
fn clone(&self) -> ReplayContext
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 moreAuto Trait Implementations§
impl Freeze for ReplayContext
impl RefUnwindSafe for ReplayContext
impl Send for ReplayContext
impl Sync for ReplayContext
impl Unpin for ReplayContext
impl UnsafeUnpin for ReplayContext
impl UnwindSafe for ReplayContext
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