pub struct EffectExecutor { /* private fields */ }Expand description
Capability-gated write-ahead external-effect coordinator.
Implementations§
Source§impl EffectExecutor
impl EffectExecutor
Sourcepub fn new(store: Arc<dyn EffectStore>) -> Self
pub fn new(store: Arc<dyn EffectStore>) -> Self
Creates an executor using the given durable-state boundary.
Sourcepub const fn with_event_payload_policy(
self,
policy: EffectEventPayloadPolicy,
) -> Self
pub const fn with_event_payload_policy( self, policy: EffectEventPayloadPolicy, ) -> Self
Sets explicit Journal output-capture behavior.
Sourcepub async fn execute(
&self,
request: EffectRequest,
run: &RunContext,
handler: &dyn EffectHandler,
recovery: EffectRecoveryPolicy,
) -> Result<EffectOutcome, EffectExecutorError>
pub async fn execute( &self, request: EffectRequest, run: &RunContext, handler: &dyn EffectHandler, recovery: EffectRecoveryPolicy, ) -> Result<EffectOutcome, EffectExecutorError>
Executes or recovers one logical effect.
§Errors
Returns EffectExecutorError for authority, persistence, lifecycle,
ambiguity, handler, or observability failures.
Sourcepub async fn execute_reconciled(
&self,
request: EffectRequest,
run: &RunContext,
handler: &dyn EffectHandler,
reconciler: &dyn EffectReconciler,
recovery: EffectRecoveryPolicy,
) -> Result<EffectOutcome, EffectExecutorError>
pub async fn execute_reconciled( &self, request: EffectRequest, run: &RunContext, handler: &dyn EffectHandler, reconciler: &dyn EffectReconciler, recovery: EffectRecoveryPolicy, ) -> Result<EffectOutcome, EffectExecutorError>
Executes an effect and consults a remote-state reconciler before deciding whether an ambiguously started record may be retried.
This closes the common crash window where the remote side committed but
the local Completed record did not. It does not create a distributed
transaction: unresolved remote state still returns Ambiguous.
§Errors
Returns EffectExecutorError for authority, persistence, lifecycle,
reconciliation, ambiguity, handler, or observability failures.
Trait Implementations§
Source§impl Clone for EffectExecutor
impl Clone for EffectExecutor
Source§fn clone(&self) -> EffectExecutor
fn clone(&self) -> EffectExecutor
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more