DotEventOutbox.Contracts
1.0.1
dotnet add package DotEventOutbox.Contracts --version 1.0.1
NuGet\Install-Package DotEventOutbox.Contracts -Version 1.0.1
<PackageReference Include="DotEventOutbox.Contracts" Version="1.0.1" />
paket add DotEventOutbox.Contracts --version 1.0.1
#r "nuget: DotEventOutbox.Contracts, 1.0.1"
// Install DotEventOutbox.Contracts as a Cake Addin #addin nuget:?package=DotEventOutbox.Contracts&version=1.0.1 // Install DotEventOutbox.Contracts as a Cake Tool #tool nuget:?package=DotEventOutbox.Contracts&version=1.0.1
DotEventOutbox.Contracts
DotEventOutbox.Contracts
is an integral part of the DotEventOutbox library, designed to aid in the implementation of the outbox pattern within .NET applications using MediatR and Entity Framework. It consists of essential interfaces and classes that define and manage domain events.
Key Components
IEvent
Interface
- Purpose: Serves as the foundational interface for all domain events in your application.
- Features:
- Inherits from
MediatR.INotification
, enabling compatibility with MediatR's messaging and handler patterns. - Includes properties for a unique event identifier (
Id
) and the timestamp of the event's occurrence (OccurredOnUtc
).
- Inherits from
DomainEvent
Record
- Purpose: Provides an abstract base record for domain events.
- Features:
- Offers default implementations for the
IEvent
interface. - Automatically generates a unique identifier (
Id
) and sets the occurrence timestamp to the current UTC time, simplifying domain event creation.
- Offers default implementations for the
IDomainEventEmitter
Interface
- Purpose: Defines the contract for objects that can emit domain events.
- Features:
- Contains a property to access a read-only collection of domain events (
Events
). - Includes a method to clear these events (
ClearEvents
), facilitating event tracking and lifecycle management.
- Contains a property to access a read-only collection of domain events (
These components collectively provide the foundation for effective domain event management in applications, ensuring consistency, idempotency, and seamless integration with MediatR and Entity Framework.
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net8.0 is compatible. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. |
-
net8.0
- MediatR.Contracts (>= 2.0.1)
NuGet packages (1)
Showing the top 1 NuGet packages that depend on DotEventOutbox.Contracts:
Package | Downloads |
---|---|
DotEventOutbox
DotEventOutbox is a powerful .NET library created to enhance the implementation of the outbox pattern, integrating seamlessly with MediatR and Entity Framework. This library is key in ensuring that domain events are processed in a reliable, consistent, and idempotent manner. |
GitHub repositories
This package is not used by any popular GitHub repositories.