Skip to main content

CheckpointStore

Trait CheckpointStore 

Source
pub trait CheckpointStore: Send + Sync {
Show 13 methods // Required methods fn create_checkpoint( &self, checkpoint: Checkpoint, ) -> CheckpointResult<bool>; fn load_checkpoint( &self, checkpoint_key: &str, ) -> CheckpointResult<Option<Checkpoint>>; fn claim_checkpoint( &self, checkpoint_key: &str, cycle_index: u64, claim_token: &str, lease_expires_at_ms: u64, now_ms: u64, claim_mode: ClaimMode, ) -> CheckpointResult<Option<Checkpoint>>; fn progress_checkpoint( &self, checkpoint: Checkpoint, claim_token: &str, expected_revision: u64, ) -> CheckpointResult<bool>; fn suspend_checkpoint( &self, checkpoint: Checkpoint, claim_token: &str, expected_revision: u64, ) -> CheckpointResult<bool>; fn commit_checkpoint( &self, checkpoint: Checkpoint, claim_token: &str, expected_revision: u64, ) -> CheckpointResult<bool>; fn finalize_claimed_checkpoint( &self, checkpoint: Checkpoint, claim_token: &str, expected_revision: u64, ) -> CheckpointResult<bool>; fn finalize_checkpoint( &self, checkpoint: Checkpoint, expected_revision: u64, ) -> CheckpointResult<bool>; fn renew_checkpoint_claim( &self, checkpoint_key: &str, claim_token: &str, lease_expires_at_ms: u64, now_ms: u64, ) -> CheckpointResult<bool>; fn record_event_delivery( &self, checkpoint_key: &str, claim_token: Option<&str>, expected_revision: u64, event_id: &str, payload_digest: &str, cursor: EventCursor, ) -> CheckpointResult<bool>; fn acknowledge_terminal( &self, checkpoint_key: &str, expected_revision: u64, ) -> CheckpointResult<bool>; fn delete_checkpoint(&self, checkpoint_key: &str) -> CheckpointResult<()>; fn list_checkpoints(&self) -> CheckpointResult<Vec<String>>;
}

Required Methods§

Source

fn create_checkpoint(&self, checkpoint: Checkpoint) -> CheckpointResult<bool>

Source

fn load_checkpoint( &self, checkpoint_key: &str, ) -> CheckpointResult<Option<Checkpoint>>

Source

fn claim_checkpoint( &self, checkpoint_key: &str, cycle_index: u64, claim_token: &str, lease_expires_at_ms: u64, now_ms: u64, claim_mode: ClaimMode, ) -> CheckpointResult<Option<Checkpoint>>

Source

fn progress_checkpoint( &self, checkpoint: Checkpoint, claim_token: &str, expected_revision: u64, ) -> CheckpointResult<bool>

Source

fn suspend_checkpoint( &self, checkpoint: Checkpoint, claim_token: &str, expected_revision: u64, ) -> CheckpointResult<bool>

Source

fn commit_checkpoint( &self, checkpoint: Checkpoint, claim_token: &str, expected_revision: u64, ) -> CheckpointResult<bool>

Source

fn finalize_claimed_checkpoint( &self, checkpoint: Checkpoint, claim_token: &str, expected_revision: u64, ) -> CheckpointResult<bool>

Source

fn finalize_checkpoint( &self, checkpoint: Checkpoint, expected_revision: u64, ) -> CheckpointResult<bool>

Source

fn renew_checkpoint_claim( &self, checkpoint_key: &str, claim_token: &str, lease_expires_at_ms: u64, now_ms: u64, ) -> CheckpointResult<bool>

Source

fn record_event_delivery( &self, checkpoint_key: &str, claim_token: Option<&str>, expected_revision: u64, event_id: &str, payload_digest: &str, cursor: EventCursor, ) -> CheckpointResult<bool>

Source

fn acknowledge_terminal( &self, checkpoint_key: &str, expected_revision: u64, ) -> CheckpointResult<bool>

Source

fn delete_checkpoint(&self, checkpoint_key: &str) -> CheckpointResult<()>

Source

fn list_checkpoints(&self) -> CheckpointResult<Vec<String>>

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§