configuring-opentelemetry-dotnet
CommunityAdd observability to ASP.NET Core apps
Authordodyg
Version1.0.0
Installs0
System Documentation
What problem does it solve?
Instrumenting ASP.NET Core applications to capture distributed traces, metrics, and correlated logs is repetitive and error-prone; this guide standardizes configuration so services reliably emit observability data for debugging, performance analysis, and operational monitoring.
Core Features & Use Cases
- Traces and Spans: Configure automatic ASP.NET Core and HttpClient instrumentation and create custom ActivitySource spans for business operations.
- Metrics: Register meters via DI and record counters, histograms, and up/down counters for application-level metrics.
- Logging Correlation and Export: Integrate ILogger with OpenTelemetry so logs include TraceId/SpanId, and export traces, metrics, and logs via OTLP to collectors like Jaeger or an OTLP-compatible backend.
- Use Case: Add this configuration to a web API to trace request flows, correlate exceptions to spans via ILogger, and export metrics for latency and throughput to your backend.
Quick Start
Add OpenTelemetry to your ASP.NET Core project, enable the OTLP exporter, register matching AddSource and AddMeter names, and start collecting traces, metrics, and correlated logs.
Dependency Matrix
Required Modules
None requiredComponents
Standard package💻 Claude Code Installation
Recommended: Let Claude install automatically. Simply copy and paste the text below to Claude Code.
Please help me install this Skill: Name: configuring-opentelemetry-dotnet Download link: https://github.com/dodyg/blue-nile-pds/archive/main.zip#configuring-opentelemetry-dotnet Please download this .zip file, extract it, and install it in the .claude/skills/ directory.
Agent Skills Search Helper
Install a tiny helper to your Agent, search and equip skill from 471,000+ vetted skills library on demand.