Table of Contents

Class AsiBackboneGovernanceOutboxDrainWorkerOptions

Namespace
AsiBackbone.AspNetCore.Outbox
Assembly
AsiBackbone.AspNetCore.dll

Provides host-owned scheduling options for the governance outbox drain worker.

public sealed class AsiBackboneGovernanceOutboxDrainWorkerOptions
Inheritance
AsiBackboneGovernanceOutboxDrainWorkerOptions
Inherited Members

Remarks

The hosted worker is local to the process in which it is registered. In horizontally scaled deployments, each replica may run its own worker unless the host disables extra replicas, partitions work, or adds durable claiming.

Properties

BatchSize

Gets or sets the maximum number of pending or retry-ready entries attempted per drain pass.

public int BatchSize { get; set; }

Property Value

int

DrainOnShutdown

Gets or sets a value indicating whether a final drain pass should be attempted during host shutdown.

public bool DrainOnShutdown { get; set; }

Property Value

bool

Remarks

Avoid enabling shutdown drains on many replicas against the same durable outbox unless duplicate-emission behavior is controlled through partitioning, durable claiming, or provider-side idempotency.

Enabled

Gets or sets a value indicating whether the hosted drain worker should run.

public bool Enabled { get; set; }

Property Value

bool

Remarks

For multi-replica hosts, enable this only on the selected worker role or partition owner unless the outbox store provides host-owned claim/lease behavior before provider emission.

FailureDelay

Gets or sets the delay after an unexpected worker-level failure before the next drain pass is attempted.

public TimeSpan FailureDelay { get; set; }

Property Value

TimeSpan

PollingInterval

Gets or sets the interval between drain passes when the worker is enabled.

public TimeSpan PollingInterval { get; set; }

Property Value

TimeSpan

RetryClock

Gets or sets the retry clock used when finding retry-ready entries.

public Func<DateTimeOffset> RetryClock { get; set; }

Property Value

Func<DateTimeOffset>

ShutdownDrainTimeout

Gets or sets the maximum amount of time allowed for an optional shutdown drain pass.

public TimeSpan ShutdownDrainTimeout { get; set; }

Property Value

TimeSpan

Methods

Validate()

Validates the configured worker options.

public void Validate()

Exceptions

InvalidOperationException

Thrown when a required worker option is invalid.