ArkaSoftware.Extensions.Events.Abstractions 2.0.0

dotnet add package ArkaSoftware.Extensions.Events.Abstractions --version 2.0.0
                    
NuGet\Install-Package ArkaSoftware.Extensions.Events.Abstractions -Version 2.0.0
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="ArkaSoftware.Extensions.Events.Abstractions" Version="2.0.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="ArkaSoftware.Extensions.Events.Abstractions" Version="2.0.0" />
                    
Directory.Packages.props
<PackageReference Include="ArkaSoftware.Extensions.Events.Abstractions" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add ArkaSoftware.Extensions.Events.Abstractions --version 2.0.0
                    
#r "nuget: ArkaSoftware.Extensions.Events.Abstractions, 2.0.0"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package ArkaSoftware.Extensions.Events.Abstractions@2.0.0
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=ArkaSoftware.Extensions.Events.Abstractions&version=2.0.0
                    
Install as a Cake Addin
#tool nuget:?package=ArkaSoftware.Extensions.Events.Abstractions&version=2.0.0
                    
Install as a Cake Tool

Extensions.Events.Abstractions

Extensions.Events.Abstractions provides a minimal and clean abstraction for implementing the Outbox Pattern in .NET applications. It helps ensure reliable event publishing by persisting domain events before dispatch, and marking them as processed after publication.


🚀 Why Outbox Pattern?

The Outbox Pattern is essential in event-driven or microservices architectures to guarantee that events are reliably stored and eventually published even in case of transient failures.


🔧 Interfaces

IOutBoxEventItemRepository

Defines the contract for accessing and processing pending outbox events.

public interface IOutBoxEventItemRepository
{
    List<OutBoxEventItem> GetOutBoxEventItemsForPublishe(int maxCount = 100);
    void MarkAsRead(List<OutBoxEventItem> outBoxEventItems);
}

🧱 Model

OutBoxEventItem

Represents a single outbox event entry with contextual information for auditing and correlation.

public class OutBoxEventItem
{
    public long OutBoxEventItemId { get; set; }
    public Guid EventId { get; set; }
    public string AccuredByUserId { get; set; }
    public DateTime AccuredOn { get; set; }
    public string AggregateName { get; set; }
    public string AggregateTypeName { get; set; }
    public string AggregateId { get; set; }
    public string EventName { get; set; }
    public string EventTypeName { get; set; }
    public string EventPayload { get; set; }
    public string? TraceId { get; set; }
    public string? SpanId { get; set; }
    public bool IsProcessed { get; set; }
}

💡 Typical Usage

-You implement IOutBoxEventItemRepository with your preferred persistence (e.g., EF Core, Dapper).

-Events are stored as OutBoxEventItem after domain actions.

-A background job or publisher picks up unprocessed events and dispatches them.

-Once dispatched, the event is marked as processed.


✅ Benefits

-Ensures at-least-once delivery of events.

-Helps in building reliable messaging pipelines.

-Decouples event publishing from transaction logic.

-Ideal for systems using event sourcing, CQRS, or microservices.


🏢 Maintained by

ArkaSoftware
📧 Email Us
🌐 Web Site Visit

Product Compatible and additional computed target framework versions.
.NET net9.0 is compatible.  net9.0-android was computed.  net9.0-browser was computed.  net9.0-ios was computed.  net9.0-maccatalyst was computed.  net9.0-macos was computed.  net9.0-tvos was computed.  net9.0-windows was computed.  net10.0 was computed.  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. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
  • net9.0

    • No dependencies.

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
2.0.0 260 4/16/2025
1.0.0 209 4/16/2024