pub trait HeaderSyncGapProvider: Send + Sync {
// Required method
fn sync_gap(
&self,
tip: Receiver<B256>,
highest_uninterrupted_block: BlockNumber,
) -> ProviderResult<HeaderSyncGap>;
}
Expand description
Client trait for determining the current headers sync gap.
Required Methods§
Sourcefn sync_gap(
&self,
tip: Receiver<B256>,
highest_uninterrupted_block: BlockNumber,
) -> ProviderResult<HeaderSyncGap>
fn sync_gap( &self, tip: Receiver<B256>, highest_uninterrupted_block: BlockNumber, ) -> ProviderResult<HeaderSyncGap>
Find a current sync gap for the headers depending on the last uninterrupted block number. Last uninterrupted block represents the block number before which there are no gaps. It’s up to the caller to ensure that last uninterrupted block is determined correctly.