Arbiter.Communication.Azure
6.12.2
dotnet add package Arbiter.Communication.Azure --version 6.12.2
NuGet\Install-Package Arbiter.Communication.Azure -Version 6.12.2
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="Arbiter.Communication.Azure" Version="6.12.2" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Arbiter.Communication.Azure" Version="6.12.2" />
<PackageReference Include="Arbiter.Communication.Azure" />
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 Arbiter.Communication.Azure --version 6.12.2
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: Arbiter.Communication.Azure, 6.12.2"
#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 Arbiter.Communication.Azure@6.12.2
#: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=Arbiter.Communication.Azure&version=6.12.2
#tool nuget:?package=Arbiter.Communication.Azure&version=6.12.2
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
Arbiter
A powerful, lightweight, and extensible implementation of the Mediator pattern and Command Query Responsibility Segregation (CQRS) for .NET applications.
Arbiter is designed for building clean, modular architectures like Vertical Slice Architecture and CQRS. It provides a comprehensive suite of libraries that work together to simplify complex application patterns while maintaining high performance and flexibility.
Key Features
- Clean Architecture: Perfect for Vertical Slice Architecture and CQRS patterns
- High Performance: Minimal overhead with efficient mediator implementation
- Extensible: Pipeline behaviors, custom handlers, and extensive customization options
- Observable: Built-in OpenTelemetry support for tracing and metrics
- Database Agnostic: Support for Entity Framework Core, MongoDB, and more
- Web Ready: Minimal API endpoints and MVC controller support
- Communication: Integrated email and SMS messaging capabilities
- Blazor Ready: First-class Dispatcher support for Blazor Auto, Server Interactive, and WebAssembly render modes
Table of Contents
- Quick Start
- Packages
- Core Libraries
- Data Providers
- Web Integration
- Blazor Dispatcher
- Documentation
- Samples
- Contributing
- License
Quick Start
Get started with Arbiter in just a few steps:
1. Install the Core Package
dotnet add package Arbiter.Mediation
2. Define a Request and Handler
// Define your request
public class GetUserQuery : IRequest<User>
{
public int UserId { get; set; }
}
// Implement the handler
public class GetUserHandler : IRequestHandler<GetUserQuery, User>
{
public async ValueTask<User?> Handle(GetUserQuery request, CancellationToken cancellationToken)
{
// Your business logic here
return await GetUserFromDatabase(request.UserId);
}
}
3. Register Services
services.AddMediator();
services.AddTransient<IRequestHandler<GetUserQuery, User>, GetUserHandler>();
4. Use the Mediator
public class UserController : ControllerBase
{
private readonly IMediator _mediator;
public UserController(IMediator mediator) => _mediator = mediator;
[HttpGet("{id}")]
public async Task<User> GetUser(int id)
{
return await _mediator.Send(new GetUserQuery { UserId = id });
}
}
Packages
Core Libraries Packages
| Library | Package | Description |
|---|---|---|
| Arbiter.Mediation | Lightweight and extensible implementation of the Mediator pattern | |
| Arbiter.Queue | Background request queue for mediator commands | |
| Arbiter.CommandQuery | Base package for Commands, Queries and Behaviors | |
| Arbiter.Mapping | Source-generated, compile-time object mapping | |
| Arbiter.Services | Utility services for CSV, encryption, caching, and tokens | |
| Arbiter.Communication | Message template communication for email and SMS services |
Data Providers Packages
| Library | Package | Description |
|---|---|---|
| Arbiter.CommandQuery.EntityFramework | Entity Framework Core handlers for the base Commands and Queries | |
| Arbiter.CommandQuery.MongoDB | MongoDB handlers for the base Commands and Queries |
Web Integration Packages
| Library | Package | Description |
|---|---|---|
| Arbiter.CommandQuery.Endpoints | Minimal API endpoints for base Commands and Queries | |
| Arbiter.CommandQuery.Mvc | MVC Controllers for base Commands and Queries |
Blazor Dispatcher Packages
| Library | Package | Description |
|---|---|---|
| Arbiter.Dispatcher.Server | ASP.NET Core endpoint that receives dispatcher messages from Blazor WASM clients | |
| Arbiter.Dispatcher.Client |