Franz.Common.Mediator.Polly
3.0.0
dotnet add package Franz.Common.Mediator.Polly --version 3.0.0
NuGet\Install-Package Franz.Common.Mediator.Polly -Version 3.0.0
<PackageReference Include="Franz.Common.Mediator.Polly" Version="3.0.0" />
<PackageVersion Include="Franz.Common.Mediator.Polly" Version="3.0.0" />
<PackageReference Include="Franz.Common.Mediator.Polly" />
paket add Franz.Common.Mediator.Polly --version 3.0.0
#r "nuget: Franz.Common.Mediator.Polly, 3.0.0"
#:package Franz.Common.Mediator.Polly@3.0.0
#addin nuget:?package=Franz.Common.Mediator.Polly&version=3.0.0
#tool nuget:?package=Franz.Common.Mediator.Polly&version=3.0.0
Franz.Common.Mediator.Polly
Polly policy registration for HTTP clients and Franz Mediator request pipelines.
Overview
The package exposes two distinct registration methods. They do not have the same behavior. HTTP policies are placed in a policy registry; the package does not automatically attach them to arbitrary HttpClient or Refit registrations.
Installation
dotnet add package Franz.Common.Mediator.Polly
HTTP policy registry only
builder.Services.AddFranzResilience(builder.Configuration);
AddFranzResilience(configuration) reads the Resilience section and registers an IReadOnlyPolicyRegistry<string> containing enabled HTTP response policies for retry, advanced circuit breaker, timeout, and bulkhead. It does not register a Mediator pipeline.
Mediator and HTTP resilience
builder.Services.AddFranzResiliencev2(builder.Configuration);
AddFranzResiliencev2(configuration) registers enabled base Mediator policies and HTTP policies, composes optional named profiles, registers the policy registry, and adds PollyResiliencePipeline<TRequest, TResponse> to Mediator.
The profile sections are Resilience:MediatorProfiles and Resilience:HttpProfiles. Each profile contains a Policies array referencing the corresponding registered policy names (for example, mediator:Retry or http:Retry).
Configuration
{
"Resilience": {
"RetryPolicy": {
"Enabled": true,
"RetryCount": 3,
"RetryIntervalMilliseconds": 200
},
"CircuitBreaker": {
"Enabled": true,
"FailureThreshold": 0.5,
"MinimumThroughput": 10,
"DurationOfBreakSeconds": 30
},
"TimeoutPolicy": {
"Enabled": true,
"TimeoutSeconds": 5
},
"BulkheadPolicy": {
"Enabled": true,
"MaxParallelization": 10,
"MaxQueueSize": 20
},
"MediatorProfiles": {
"Default": {
"Policies": [
"mediator:Retry",
"mediator:CircuitBreaker",
"mediator:Timeout"
]
}
},
"HttpProfiles": {
"Default": {
"Policies": [
"http:Retry",
"http:CircuitBreaker",
"http:Timeout"
]
}
}
}
}
The base policy keys are shared configuration switches; enabling a policy registers the corresponding policy instances. Profiles compose those registered instances. Validate retry safety for each operation: automatic retries are appropriate only when the operation is idempotent or protected by an idempotency mechanism.
API naming
Use the current public methods AddFranzResilience for HTTP registry-only setup and AddFranzResiliencev2 for Mediator plus HTTP setup. Historical examples using AddFranzPollyPolicies, AddFranzPollyRetry, or separate per-policy registration methods do not describe the current package API.
License
MIT. See the repository LICENSE.
| 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. |
-
net10.0
- Franz.Common.Mediator (>= 3.0.0)
- Microsoft.Extensions.Configuration.Binder (>= 10.0.14)
- Polly (>= 8.7.0)
NuGet packages (1)
Showing the top 1 NuGet packages that depend on Franz.Common.Mediator.Polly:
| Package | Downloads |
|---|---|
|
Franz.Common.Messaging.AzureEventBus
Shared utility library for the Franz Framework. |
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 3.0.0 | 89 | 11/10/2026 |
| 2.3.4 | 366 | 11/1/2026 |
| 2.3.3 | 333 | 10/28/2026 |
| 2.3.2 | 126 | 10/27/2026 |
| 2.3.1 | 185 | 10/26/2026 |
| 2.3.0 | 366 | 7/21/2026 |
| 2.2.19 | 160 | 7/19/2026 |
| 2.2.18 | 152 | 7/19/2026 |
| 2.2.17 | 150 | 7/12/2026 |
| 2.2.16 | 157 | 7/2/2026 |
| 2.2.15 | 161 | 6/29/2026 |
| 2.2.14 | 147 | 6/29/2026 |
| 2.2.13 | 152 | 6/29/2026 |
| 2.2.12 | 153 | 6/28/2026 |
| 2.2.11 | 168 | 6/28/2026 |
| 2.2.10 | 157 | 6/28/2026 |
| 2.2.9 | 158 | 6/28/2026 |
| 2.2.8 | 152 | 6/28/2026 |
| 2.2.7 | 153 | 6/7/2026 |
| 2.2.6 | 157 | 6/6/2026 |