Skip to main content

Driver

Struct Driver 

Source
pub struct Driver { /* private fields */ }
Expand description

Bounded single-broker state. Payloads remain owned by the journal adapter.

Implementations§

Source§

impl Driver

Source

pub const fn configuration(&self) -> Configuration

Persisted single-broker identity, independent of current write readiness.

Source

pub const fn limits(&self) -> PipelineLimits

Count/byte capacity shared by all admitted operations on this partition.

Source

pub fn recover( configuration: Configuration, generation: JournalGeneration, recovered: Prefix, limits: PipelineLimits, ) -> Result<Self, Error>

Activate only after exact-identity journal recovery has validated and synchronized this prefix. A fresh, explicitly formatted store uses genesis. Unlike replicated restart, no remote agreement or election exists here.

Source

pub fn snapshot(&self) -> Snapshot

Observe local progress without changing authority.

Source

pub fn begin_validation(&self) -> Result<ValidationTicket, Error>

Capture validation authority without accepting or confirming records.

Source

pub fn prepare_validated( &mut self, ticket: ValidationTicket, operations: &[PreparedOperation], ) -> Result<WriteTicket, Error>

Admit only a fresh contiguous suffix validated on this exact image. Retries resolve in the shared canonical journal before this boundary.

Source

pub fn complete_write(&mut self, ticket: WriteTicket) -> Result<(), Error>

Physical write completion alone never confirms or exposes records.

Source

pub fn begin_sync(&self) -> Result<SyncTicket, Error>

Capture a generation-fenced durability ticket for the written prefix.

Source

pub fn complete_sync(&mut self, ticket: SyncTicket) -> Result<(), Error>

Called after both the data barrier and exact durable-prefix evidence complete. Later writes cannot extend this captured confirmation boundary.

Source

pub fn complete_durable_write( &mut self, ticket: WriteTicket, ) -> Result<(), Error>

Install a write that its O_DSYNC completion made durable, and confirm through it. Durable-prefix evidence is published separately.

Source

pub fn apply_through(&mut self, through: Prefix) -> Result<(), Error>

Release live credit only after the shared journal applies this prefix. Application visibility and confirmation replies require this boundary.

Source

pub fn fail(&mut self, generation: JournalGeneration) -> Result<(), Error>

Fence uncertain I/O until a new exact-identity recovery and generation.

Trait Implementations§

Source§

impl Debug for Driver

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
where ST: ?Sized, DT: ?Sized,

Source§

impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
where ST: ?Sized, DT: ?Sized,

Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> Read<Exclusive, BecauseExclusive> for T
where T: ?Sized,

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.