TCIS.Diagnostics.Advanced
1.0.0-rc.10
dotnet add package TCIS.Diagnostics.Advanced --version 1.0.0-rc.10
NuGet\Install-Package TCIS.Diagnostics.Advanced -Version 1.0.0-rc.10
<PackageReference Include="TCIS.Diagnostics.Advanced" Version="1.0.0-rc.10" />
<PackageVersion Include="TCIS.Diagnostics.Advanced" Version="1.0.0-rc.10" />
<PackageReference Include="TCIS.Diagnostics.Advanced" />
paket add TCIS.Diagnostics.Advanced --version 1.0.0-rc.10
#r "nuget: TCIS.Diagnostics.Advanced, 1.0.0-rc.10"
#:package TCIS.Diagnostics.Advanced@1.0.0-rc.10
#addin nuget:?package=TCIS.Diagnostics.Advanced&version=1.0.0-rc.10&prerelease
#tool nuget:?package=TCIS.Diagnostics.Advanced&version=1.0.0-rc.10&prerelease
TCIS.Diagnostics.Advanced
The TCIS.Diagnostics.Advanced library provides an automatic mechanism for performance tracking and Latency calculation for External APIs (HttpClient), while supporting proactive Health Checks based on actual latency.
🌟 Features
- Automatic Measurement: Automatically measures latency via the Delegating Handler system when registering an
HttpClient. - EMA Algorithm (Exponential Moving Average): Provides smooth and responsive average latency calculation.
- Latency Health Check: Supports proactive Health Checks (returning Degraded/Unhealthy) if the target API response time exceeds the defined threshold (Grey Failure Detection).
- OpenTelemetry Metrics: Automatically pushes the
http.client.latency.ema_msmetric into the Observability system.
📦 Installation
dotnet add package TCIS.Diagnostics.Advanced
⚙️ Configuration
You can adjust the warning thresholds for latency in the appsettings.json file:
{
"LatencyOptions": {
"DegradedThresholdMs": 2000,
"UnhealthyThresholdMs": 5000,
"ColdStartThreshold": 5,
"StaleDataThresholdSeconds": 60
}
}
🚀 Setup & Usage
1. Registering Metrics & Health Checks on HttpClient
In Program.cs, use a combination of AddTLatencyDiagnostics() and AddTLatencyHealthCheck() on the HttpClient builder chain:
using TCIS.Diagnostics.Advanced.Extensions;
var builder = WebApplication.CreateBuilder(args);
builder.Services.AddHttpClient("ExternalAppClient", client =>
{
client.BaseAddress = new Uri("http://api.external.com");
})
// Activate latency recording (metrics)
.AddTLatencyDiagnostics()
// Activate metric-based health evaluation (Health Check)
.AddTLatencyHealthCheck();
2. Observation Parameters
- Generated Metrics:
http.client.latency.ema_ms(Meter name:TCIS.Diagnostics.Latency). - Tags (Health Checks):
"latency","performance","http","dependencies".
| Product | Versions 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. net9.0 was computed. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. net10.0 was computed. 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. |
-
net8.0
- Microsoft.Extensions.Configuration (>= 9.0.0)
- Microsoft.Extensions.Configuration.Abstractions (>= 9.0.0)
- Microsoft.Extensions.Configuration.Binder (>= 9.0.0)
- Microsoft.Extensions.DependencyInjection (>= 9.0.0)
- Microsoft.Extensions.DependencyInjection.Abstractions (>= 9.0.0)
- Microsoft.Extensions.Diagnostics.HealthChecks (>= 9.0.0)
- Microsoft.Extensions.Diagnostics.HealthChecks.Abstractions (>= 9.0.0)
- Microsoft.Extensions.Hosting.Abstractions (>= 9.0.0)
- Microsoft.Extensions.Http (>= 9.0.0)
- Microsoft.Extensions.Logging (>= 9.0.0)
- Microsoft.Extensions.Logging.Abstractions (>= 9.0.0)
- Microsoft.Extensions.Options (>= 9.0.0)
- Microsoft.Extensions.Options.ConfigurationExtensions (>= 9.0.0)
- TCIS.Core (>= 1.0.0-rc.10)
NuGet packages (1)
Showing the top 1 NuGet packages that depend on TCIS.Diagnostics.Advanced:
| Package | Downloads |
|---|---|
|
TCIS.Http
TCIS Core Framework is an application framework for building modular, multi-tenant applications on ASP.NET Core. HTTP client extensions and utilities for TCIS Framework. |
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 1.0.0-rc.10 | 41 | 7/24/2026 |
| 1.0.0-rc.9 | 62 | 7/21/2026 |
| 1.0.0-rc.8 | 61 | 7/21/2026 |
| 1.0.0-rc.7 | 70 | 7/17/2026 |
| 1.0.0-rc.6 | 82 | 7/7/2026 |
| 1.0.0-rc.5 | 84 | 7/7/2026 |
| 1.0.0-rc.4 | 88 | 6/24/2026 |
| 1.0.0-rc.2 | 76 | 5/12/2026 |
| 1.0.0-rc.1 | 76 | 5/12/2026 |