WcfClient.Resilient 8.0.1

dotnet add package WcfClient.Resilient --version 8.0.1                
NuGet\Install-Package WcfClient.Resilient -Version 8.0.1                
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="WcfClient.Resilient" Version="8.0.1" />                
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add WcfClient.Resilient --version 8.0.1                
#r "nuget: WcfClient.Resilient, 8.0.1"                
#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.
// Install WcfClient.Resilient as a Cake Addin
#addin nuget:?package=WcfClient.Resilient&version=8.0.1

// Install WcfClient.Resilient as a Cake Tool
#tool nuget:?package=WcfClient.Resilient&version=8.0.1                

WcfClient.Resilient

Provides a resilient WCF client as a web service reverse proxy built on top of GenericWcfClient, featuring support for Polly's retry actions and the circuit breaker pattern.

Configuration


builder.Services.AddWcfGenericClient<IdentityService, SoapSettings>(
    config, "SoapSettings");

builder.Services.AddResilientWcfClientInstaller<IdentityService, DefaultPolicyFactory<IdentityService>>(
    config, "WcfResilient");

  • AddWcfGenericClient: Registers the IGenericWcfClient for the IdentityService.
  • AddResilientWcfClientInstaller: Adds resilient behavior to the GenericWcfClient (web service proxy) for the service that implements the IdentityService interface.

Note: The order of these registrations in the dependency injection (DI) container is important for the correct setup of resilient behavior.

Resilient Settings Example

The resilient settings for the provided example:

"WcfResilient": {
      "PolicyRetryAttempts": 3,
      "AsyncPolicyRetryAttempts": 3,
      "RetryAttemptInMilliseconds": 2000,
      "AsyncRetryAttemptInMilliseconds": 2000,
      "CircuitBreakerPolicyRetryAttempts": 2,
      "AsyncCircuitBreakerPolicyRetryAttempts": 2,
      "CircuitBreakerRetryAttemptInMilliseconds": 180000,
      "AsyncCircuitBreakerRetryAttemptInMilliseconds": 180000
    }

This configuration defines the number of retry attempts and the delay between retries for both synchronous and asynchronous calls, as well as the circuit breaker thresholds.

Product 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. 
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
8.0.1 79 11/9/2024
8.0.0 84 10/23/2024
6.0.0 71 11/9/2024

Added label templates on logging exceptions.