Sparkdo.Application
2.0.0-preview.2
This is a prerelease version of Sparkdo.Application.
dotnet add package Sparkdo.Application --version 2.0.0-preview.2
NuGet\Install-Package Sparkdo.Application -Version 2.0.0-preview.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="Sparkdo.Application" Version="2.0.0-preview.2" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Sparkdo.Application" Version="2.0.0-preview.2" />
<PackageReference Include="Sparkdo.Application" />
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 Sparkdo.Application --version 2.0.0-preview.2
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: Sparkdo.Application, 2.0.0-preview.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 Sparkdo.Application@2.0.0-preview.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=Sparkdo.Application&version=2.0.0-preview.2&prerelease
#tool nuget:?package=Sparkdo.Application&version=2.0.0-preview.2&prerelease
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
Sparkdo.Application
Sparkdo.Application 提供围绕现有 Mediation 请求管线的应用用例接线和可组合行为。运行时包以 net10.0 发布,因为现有 Mediation runtime 以 net10.0 为目标;Contracts 包保持 netstandard2.0。
最小用法
处理器直接实现现有 Mediation 契约:
using Sparkdo.Mediation;
public sealed class GetOrderHandler : IRequestHandler<GetOrder, OrderResult>
{
public ValueTask<OrderResult> HandleAsync(
GetOrder request,
CancellationToken cancellationToken) =>
ValueTask.FromResult(new OrderResult(request.Id));
}
应用可在现有 IMediatorBuilder 上接入行为:
services.AddMediator().ConfigureApplication(application =>
{
application.Use(new ApplicationBehaviorConfiguration(
"audit",
static (_, next) => next));
});
Application 不拥有请求调度、数据库或异常传输模型;它只组合 Mediation middleware,并保持行为的显式顺序和现有 IMediatorContext 生命周期。
| 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. |
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
-
net10.0
- Microsoft.Bcl.AsyncInterfaces (>= 10.0.8)
- Microsoft.Extensions.Configuration.Abstractions (>= 10.0.8)
- Microsoft.Extensions.DependencyInjection (>= 10.0.8)
- Microsoft.Extensions.DependencyInjection.Abstractions (>= 10.0.8)
- Microsoft.Extensions.FileProviders.Abstractions (>= 10.0.8)
- Microsoft.Extensions.Hosting.Abstractions (>= 10.0.8)
- Microsoft.Extensions.Logging.Abstractions (>= 10.0.8)
- Microsoft.Extensions.ObjectPool (>= 10.0.8)
- Microsoft.Extensions.Options (>= 10.0.8)
- Sparkdo.Application.Contracts (>= 2.0.0-preview.2)
- Sparkdo.Mediation (>= 2.0.0-preview.2)
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-preview.2 | 43 | 7/20/2026 |