Atya.Messaging.Outbox
1.0.0
Prefix Reserved
dotnet add package Atya.Messaging.Outbox --version 1.0.0
NuGet\Install-Package Atya.Messaging.Outbox -Version 1.0.0
<PackageReference Include="Atya.Messaging.Outbox" Version="1.0.0" />
<PackageVersion Include="Atya.Messaging.Outbox" Version="1.0.0" />
<PackageReference Include="Atya.Messaging.Outbox" />
paket add Atya.Messaging.Outbox --version 1.0.0
#r "nuget: Atya.Messaging.Outbox, 1.0.0"
#:package Atya.Messaging.Outbox@1.0.0
#addin nuget:?package=Atya.Messaging.Outbox&version=1.0.0
#tool nuget:?package=Atya.Messaging.Outbox&version=1.0.0
Atya.Messaging.Outbox
Transactional outbox store and relay primitives for reliable Atya messaging.
Overview
Atya.Messaging.Outbox captures messages in an outbox store through the existing IMessagePublisher<TMessage> contract, then relays pending messages through a transport publisher later. The package includes contracts, serialization helpers, an in-memory store for tests and simple hosts, and a relay that preserves message id, correlation id, headers, and runtime message type. Repeated publish failures are retried until the configured attempt budget is exhausted, then the message is marked Failed and is no longer loaded by the relay.
Entity Framework and broker-specific providers are intentionally out of scope for this package.
Installation
dotnet add package Atya.Messaging.Outbox
Quick Start
using Atya.Foundation.Time;
using Atya.Messaging.Abstractions;
using Atya.Messaging.Outbox;
var store = new InMemoryOutboxStore();
var clock = new SystemClock();
var outboxPublisher = new OutboxPublisher<OrderSubmitted>(store, clock);
await outboxPublisher.PublishAsync(
new OrderSubmitted("order-123"),
new MessagePublishOptions(
messageId: "message-123",
correlationId: "correlation-123"));
IMessagePublisher transportPublisher = /* adapter implemented by a transport package */;
var relay = new OutboxRelay(store, transportPublisher, clock, maxAttempts: 3);
OutboxRelayResult result = await relay.PublishPendingAsync(maxCount: 100);
public sealed record OrderSubmitted(string OrderId);
Public Surface
IOutboxStorestores pending messages and records publish outcomes. Durable implementations must participate in the caller's transaction.OutboxMessagerepresents a serialized message, metadata, status, and retry state.OutboxMessageStatushasPending,Published, and terminalFailedstates.OutboxMessageSerializerserializesMessageEnvelope<TMessage>values and restores runtime payloads from assembly-qualified type names using Atya Foundation serialization defaults unless options are supplied.OutboxPublisher<TMessage>implementsIMessagePublisher<TMessage>by writing to the outbox.OutboxRelayrepublishes pending outbox messages through the type-erasedIMessagePublishercontract and marks messages terminally failed aftermaxAttempts.InMemoryOutboxStoreprovides an in-memory implementation for tests, samples, and simple hosts.
Testing
dotnet test
Benchmarks
dotnet run -c Release --project benchmarks/Outbox.Benchmarks
License
MIT. See LICENSE.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net10.0 is compatible. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
-
net10.0
- Atya.Foundation.Guards (>= 1.0.2)
- Atya.Foundation.Serialization (>= 1.0.0)
- Atya.Foundation.Time (>= 1.0.0)
- Atya.Messaging.Abstractions (>= 1.1.0)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 1.0.0 | 272 | 7/13/2026 |