pub trait StageCheckpointReader: Send + Sync {
// Required methods
fn get_stage_checkpoint(
&self,
id: StageId,
) -> ProviderResult<Option<StageCheckpoint>>;
fn get_stage_checkpoint_progress(
&self,
id: StageId,
) -> ProviderResult<Option<Vec<u8>>>;
fn get_all_checkpoints(
&self,
) -> ProviderResult<Vec<(String, StageCheckpoint)>>;
}
Expand description
The trait for fetching stage checkpoint related data.
Required Methods§
Sourcefn get_stage_checkpoint(
&self,
id: StageId,
) -> ProviderResult<Option<StageCheckpoint>>
fn get_stage_checkpoint( &self, id: StageId, ) -> ProviderResult<Option<StageCheckpoint>>
Fetch the checkpoint for the given stage.
Sourcefn get_stage_checkpoint_progress(
&self,
id: StageId,
) -> ProviderResult<Option<Vec<u8>>>
fn get_stage_checkpoint_progress( &self, id: StageId, ) -> ProviderResult<Option<Vec<u8>>>
Get stage checkpoint progress.
Sourcefn get_all_checkpoints(&self) -> ProviderResult<Vec<(String, StageCheckpoint)>>
fn get_all_checkpoints(&self) -> ProviderResult<Vec<(String, StageCheckpoint)>>
Reads all stage checkpoints and returns a list with the name of the stage and the checkpoint data.