pub struct DurableGraphDriver { /* private fields */ }Expand description
Fenced durable graph execution service over one PostgreSQL provider pool.
Implementations§
Source§impl DurableGraphDriver
impl DurableGraphDriver
Sourcepub fn new(
store: PostgresStore,
registry: ExecutableGraphRegistry,
options: DurableGraphDriverOptions,
) -> Result<Self, DurableGraphDriverBuildError>
pub fn new( store: PostgresStore, registry: ExecutableGraphRegistry, options: DurableGraphDriverOptions, ) -> Result<Self, DurableGraphDriverBuildError>
Binds one provider pool and frozen executable registry.
The standard event schema must have been installed before the schema registry was frozen. Renewal cadence must fit at least three times in a newly acquired lease, preserving time for two delayed renewal cycles.
§Errors
Returns DurableGraphDriverBuildError for an invalid release schema,
absent journal schema, or unsafe lease cadence.
Sourcepub fn execution_activity(&self) -> GraphExecutionActivity
pub fn execution_activity(&self) -> GraphExecutionActivity
Returns shared node-future completion accounting for this driver and clones.
Sourcepub const fn options(&self) -> DurableGraphDriverOptions
pub const fn options(&self) -> DurableGraphDriverOptions
Returns the immutable execution policy.
Sourcepub fn drive(
&self,
fence: RunFence,
shutdown: CancellationSignal,
) -> BoxFuture<'_, Result<GraphDriveResult, GraphDriverError>>
pub fn drive( &self, fence: RunFence, shutdown: CancellationSignal, ) -> BoxFuture<'_, Result<GraphDriveResult, GraphDriverError>>
Replays and drives one already-claimed exact worker fence.
Every node start commits before node code is spawned. An idempotently observed start is never launched. The node task holds no database transaction, receives a monotonic cancellation signal, and is aborted if renewal, shutdown, or its deadline wins. Successful and failed node completions use the latest exact journal head so invocation-ledger facts committed by the node remain ordered before its result.
Continue barriers commit automatically. Wait and successful-terminal barriers, plus node failure/exhaustion, return a lease-bound handoff: their complete registration, admitted result, or cumulative failure metadata belongs to the lifecycle integration layer and is never guessed by this driver.
§Errors
Returns explicit storage, fencing, executable-deployment, schema, planning, resource, or runtime invariant failures. Durable corruption is quarantined by the claimed recovery session before it reaches this API.
Trait Implementations§
Source§impl Clone for DurableGraphDriver
impl Clone for DurableGraphDriver
Auto Trait Implementations§
impl !RefUnwindSafe for DurableGraphDriver
impl !UnwindSafe for DurableGraphDriver
impl Forget for DurableGraphDriver
impl Freeze for DurableGraphDriver
impl Move for DurableGraphDriver
impl Send for DurableGraphDriver
impl Sync for DurableGraphDriver
impl Unpin for DurableGraphDriver
impl UnsafeUnpin for DurableGraphDriver
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more