VOOZH about

URL: https://www.nuget.org/packages/CleanArchitecture.Core.Infrastructure/

⇱ NuGet Gallery | CleanArchitecture.Core.Infrastructure 1.0.0-alpha.4




CleanArchitecture.Core.Infrastructure 1.0.0-alpha.4

This is a prerelease version of CleanArchitecture.Core.Infrastructure.
dotnet add package CleanArchitecture.Core.Infrastructure --version 1.0.0-alpha.4
 
 
NuGet\Install-Package CleanArchitecture.Core.Infrastructure -Version 1.0.0-alpha.4
 
 
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="CleanArchitecture.Core.Infrastructure" Version="1.0.0-alpha.4" />
 
 
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="CleanArchitecture.Core.Infrastructure" Version="1.0.0-alpha.4" />
 
Directory.Packages.props
<PackageReference Include="CleanArchitecture.Core.Infrastructure" />
 
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 CleanArchitecture.Core.Infrastructure --version 1.0.0-alpha.4
 
 
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: CleanArchitecture.Core.Infrastructure, 1.0.0-alpha.4"
 
 
#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 CleanArchitecture.Core.Infrastructure@1.0.0-alpha.4
 
 
#: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=CleanArchitecture.Core.Infrastructure&version=1.0.0-alpha.4&prerelease
 
Install as a Cake Addin
#tool nuget:?package=CleanArchitecture.Core.Infrastructure&version=1.0.0-alpha.4&prerelease
 
Install as a Cake Tool
The NuGet Team does not provide support for this client. Please contact its maintainers for support.

CleanArchitecture.Core.Infrastructure

Core infrastructure implementations including custom mediator, event dispatchers, and dependency injection extensions for Clean Architecture.

Purpose

This package provides ready-to-use implementations of IMediator, IDomainEventDispatcher, and IIntegrationEventDispatcher with dependency injection extensions. It works with CleanArchitecture.Core.Application to provide a complete CQRS and event-driven architecture foundation.

Installation

dotnet add package CleanArchitecture.Core.Infrastructure

Usage

Register Infrastructure Services

services.AddCoreInfrastructure();

Custom Configuration

services.AddCoreInfrastructure(options =>
{
 options.RegisterConvention = true;
 // or provide custom convention
 options.CustomConvention = new CustomIntegrationEventConvention();
});

Use Mediator

public class ProductService
{
 private readonly IMediator _mediator;
 
 public ProductService(IMediator mediator)
 {
 _mediator = mediator;
 }
 
 public async Task<Result<Guid>> CreateProduct(string name)
 {
 var command = new CreateProductCommand(name);
 return await _mediator.Send(command);
 }
}

Use Event Dispatchers

public class OrderService
{
 private readonly IDomainEventDispatcher _domainEventDispatcher;
 private readonly IIntegrationEventDispatcher _integrationEventDispatcher;
 
 public async Task CompleteOrder(Order order)
 {
 // Domain events are dispatched within transaction
 await _domainEventDispatcher.PublishAsync(new OrderCompletedEvent(order.Id));
 
 // Integration events are dispatched via outbox pattern
 await _integrationEventDispatcher.PublishAsync(new OrderCompletedIntegrationEvent(order.Id));
 }
}

Key Components

  • CustomMediator - Implementation of IMediator
  • DomainEventDispatcher - Implementation of IDomainEventDispatcher
  • IntegrationEventDispatcher - Implementation of IIntegrationEventDispatcher
  • DefaultIntegrationEventConvention - Default convention for discovering integration events

Dependencies

Requires CleanArchitecture.Core.Application and CleanArchitecture.Core.Domain.

Repository

GitHub: https://github.com/mohd2sh/CleanArchitecture-DDD-CQRS

License

MIT

Product Versions Compatible and additional computed target framework versions.
.NET net8.0 net8.0 is compatible.  net8.0-android net8.0-android was computed.  net8.0-browser net8.0-browser was computed.  net8.0-ios net8.0-ios was computed.  net8.0-maccatalyst net8.0-maccatalyst was computed.  net8.0-macos net8.0-macos was computed.  net8.0-tvos net8.0-tvos was computed.  net8.0-windows net8.0-windows was computed.  net9.0 net9.0 was computed.  net9.0-android net9.0-android was computed.  net9.0-browser net9.0-browser was computed.  net9.0-ios net9.0-ios was computed.  net9.0-maccatalyst net9.0-maccatalyst was computed.  net9.0-macos net9.0-macos was computed.  net9.0-tvos net9.0-tvos was computed.  net9.0-windows net9.0-windows was computed.  net10.0 net10.0 was computed.  net10.0-android net10.0-android was computed.  net10.0-browser net10.0-browser was computed.  net10.0-ios net10.0-ios was computed.  net10.0-maccatalyst net10.0-maccatalyst was computed.  net10.0-macos net10.0-macos was computed.  net10.0-tvos net10.0-tvos was computed.  net10.0-windows net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

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-alpha.4 203 11/10/2025
1.0.0-alpha.3 186 11/10/2025