Skip to main content

TypedSeekable

Trait TypedSeekable 

Source
pub trait TypedSeekable: Send + Sync {
    // Required methods
    fn seek_typed(
        &mut self,
        position: &SourcePosition,
    ) -> Result<(), RecoveryError>;
    fn source_id(&self) -> &str;

    // Provided method
    fn can_seek_to(&self, position: &SourcePosition) -> bool { ... }
}
Expand description

Trait for source connectors that can seek using a typed SourcePosition.

This extends the raw string-based Seekable trait with type-safe position tracking for exactly-once semantics (F-E2E-001).

Required Methods§

Source

fn seek_typed(&mut self, position: &SourcePosition) -> Result<(), RecoveryError>

Seek the source to a typed checkpoint position.

§Errors

Returns RecoveryError::SeekFailed if the source cannot seek to the given position.

Source

fn source_id(&self) -> &str

Source identifier (must match the key in the manifest).

Provided Methods§

Source

fn can_seek_to(&self, position: &SourcePosition) -> bool

Validate that the source can seek to the given position.

Returns false if the position is unreachable (e.g., Kafka retention expired, replication slot dropped).

Implementors§