AuroraScienceHub.Framework.Logging.OpenTelemetry 10.1.0

Prefix Reserved
dotnet add package AuroraScienceHub.Framework.Logging.OpenTelemetry --version 10.1.0
                    
NuGet\Install-Package AuroraScienceHub.Framework.Logging.OpenTelemetry -Version 10.1.0
                    
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="AuroraScienceHub.Framework.Logging.OpenTelemetry" Version="10.1.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="AuroraScienceHub.Framework.Logging.OpenTelemetry" Version="10.1.0" />
                    
Directory.Packages.props
<PackageReference Include="AuroraScienceHub.Framework.Logging.OpenTelemetry" />
                    
Project file
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 AuroraScienceHub.Framework.Logging.OpenTelemetry --version 10.1.0
                    
#r "nuget: AuroraScienceHub.Framework.Logging.OpenTelemetry, 10.1.0"
                    
#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 AuroraScienceHub.Framework.Logging.OpenTelemetry@10.1.0
                    
#: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=AuroraScienceHub.Framework.Logging.OpenTelemetry&version=10.1.0
                    
Install as a Cake Addin
#tool nuget:?package=AuroraScienceHub.Framework.Logging.OpenTelemetry&version=10.1.0
                    
Install as a Cake Tool

AuroraScienceHub.Framework.Logging.OpenTelemetry

OpenTelemetry logging integration for distributed tracing and observability in .NET applications.

Overview

Provides simplified OpenTelemetry logging configuration with automatic resource detection and application naming for distributed systems monitoring.

Key Features

  • OpenTelemetry Integration - Structured logging with OpenTelemetry
  • Automatic Resource Tagging - Application name and namespace detection
  • Distributed Tracing - Correlation across microservices
  • Observability Ready - Works with Grafana, Jaeger, etc.

Installation

dotnet add package AuroraScienceHub.Framework.Logging.OpenTelemetry

Usage

Basic Setup

// Program.cs
var builder = WebApplication.CreateBuilder(args);

builder.Logging.AddOpenTelemetryLogging(builder.Configuration);

var app = builder.Build();

Configuration

{
  "Host": {
    "Name": "user-service",
    "Namespace": "production"
  }
}

Complete OpenTelemetry Setup

builder.Services.AddOpenTelemetry()
    .WithTracing(tracing =>
    {
        tracing
            .AddAspNetCoreInstrumentation()
            .AddHttpClientInstrumentation()
            .AddEntityFrameworkCoreInstrumentation();
    })
    .WithMetrics(metrics =>
    {
        metrics
            .AddAspNetCoreInstrumentation()
            .AddRuntimeInstrumentation();
    });

builder.Logging.AddOpenTelemetryLogging(builder.Configuration);

// Configure exporter
builder.Services.ConfigureOpenTelemetryTracerProvider(tracing =>
{
    tracing.AddOtlpExporter(options =>
    {
        options.Endpoint = new Uri("http://localhost:4317");
    });
});

Structured Logging

public class OrderService
{
    private readonly ILogger<OrderService> _logger;

    public async Task<Order> CreateOrderAsync(CreateOrderCommand command)
    {
        using var scope = _logger.BeginScope(new Dictionary<string, object>
        {
            ["OrderId"] = command.OrderId,
            ["CustomerId"] = command.CustomerId
        });

        _logger.LogInformation("Creating order for customer {CustomerId}", command.CustomerId);

        // ... create order

        _logger.LogInformation("Order {OrderId} created successfully", order.Id);
        return order;
    }
}

License

See LICENSE file in the repository root.

  • AuroraScienceHub.Framework.Diagnostics - Health checks and diagnostics
  • AuroraScienceHub.Framework.AspNetCore - ASP.NET Core integration
Product 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.

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
10.1.0 77 8/19/2026
10.0.8 89 8/14/2026
10.0.7 99 8/11/2026
10.0.6 88 8/11/2026
10.0.5 131 4/23/2026
10.0.4 124 4/23/2026
10.0.3 142 2/11/2026
10.0.2 135 1/29/2026
10.0.1 234 12/25/2025
10.0.0 448 12/11/2025
9.0.7 440 11/20/2025
9.0.6 201 11/15/2025
9.0.5 150 11/8/2025
9.0.4 161 10/24/2025
9.0.3 219 10/15/2025
9.0.2 202 10/15/2025
9.0.1 205 10/14/2025
9.0.1-workflow-test-2.17 162 10/14/2025