Skip to main content
Table of Contents

Namespace Stratara.Abstractions.Outbox

Classes

OutboxEntry

Durable outbox row — persists a serialised payload (command envelope or event bundle) for later delivery by the outbox worker. Written by dispatchers when the direct bus publish fails.

RecordedIntent

A recorded command as an ICommandIntentStore returns it for resumption.

Interfaces

ICommandIntentStore

Where an execution model that records every accepted command keeps the bookkeeping of its resume: the command with the aggregate it names and whether it is heavy, how often it has been handed over, how many of its attempts ended in a concurrency conflict, when it was last handed over, the failure of its last attempt, and whether it has been kept for an operator. The resume is bounded only as far as an implementation persists these; an execution model that requires this port fails at start when none is registered, rather than resuming without a bound.

ICommandOutboxDispatcher

Enqueues commands for asynchronous out-of-process execution by the command-handling worker. Implementations first try direct publish (fast path) and fall back to the outbox table if the bus is unreachable.

IEventBundleOutboxDispatcher

Enqueues event bundles produced by the event-source on save for projection and saga workers to consume. Implementations first try direct publish and fall back to the outbox table if the bus is unreachable — or, where StoresBundlesWithCommit says so, write the bundle to durable storage in the transaction that commits its events and remove it once the bus has accepted it.

IOutboxLock

Mutual-exclusion primitive that coordinates outbox-drain access across multiple host instances. The outbox worker calls TryAcquireAsync(TimeSpan, CancellationToken) at the start of every polling cycle; only the instance that receives a non-null handle proceeds to drain. Other instances skip the cycle and re-attempt at the next poll interval.

IOutboxLockHandle

Disposable handle returned by TryAcquireAsync(TimeSpan, CancellationToken). Disposing the handle releases the lock; if disposal fails or never runs, the lock is auto-released once the lease expires in the underlying store.

IOutboxRepository

Repository over the outbox_entry table — durable queue of messages that couldn't be published directly to the bus and are retried by the outbox worker.