AzureMonitorLogs.Exporter.OpenTelemetry 1.0.1

The owner has unlisted this package. This could mean that the package is deprecated, has security vulnerabilities or shouldn't be used anymore.
dotnet add package AzureMonitorLogs.Exporter.OpenTelemetry --version 1.0.1
NuGet\Install-Package AzureMonitorLogs.Exporter.OpenTelemetry -Version 1.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="AzureMonitorLogs.Exporter.OpenTelemetry" Version="1.0.1" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add AzureMonitorLogs.Exporter.OpenTelemetry --version 1.0.1
#r "nuget: AzureMonitorLogs.Exporter.OpenTelemetry, 1.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 AzureMonitorLogs.Exporter.OpenTelemetry as a Cake Addin
#addin nuget:?package=AzureMonitorLogs.Exporter.OpenTelemetry&version=1.0.1

// Install AzureMonitorLogs.Exporter.OpenTelemetry as a Cake Tool
#tool nuget:?package=AzureMonitorLogs.Exporter.OpenTelemetry&version=1.0.1

Supported .NET Versions:

Package is targeting .NET 7 and above.

Background:

AzureMonitorLogs Exporter is an open-source project that provides a simple and efficient way to export telemetry data from your application to Azure Log Analytics. The project is based on open telemetry dotnet implementation, adding a dedicated exporter targeting Log Analytics.

Suported instrumentation

Signal Status
Traces Supported
Logs Not supported
Metrics Not supported

Supported protocols and main traits:

Data Collector api:

Requirements for usage:
  • Azure log analytics Workspace is provisioned and known.
  • Workspace immutable id.
  • Workspace shared key, either primary or secondary.
  • Exporter will target user specified custom log table, creating it on the fly, when required.

Ingestion api:

Requirements for usage:
  • Azure log analytics Workspace is provisioned and known.
  • Workspace immutable id.
  • Application is provisioned and known, representing the to be instrumented service.
  • Dcr and Dce.
  • Application was granted the appropriate permission to Dcr.
  • A log analytics custom log table was provisioned in advance, targeting open telemetry trace schema.
  • Dcr stream definition depicting schema must match destination custom log table schema.
Important to note - Ingestion api tutorial on how to set Application and Permissions
Expected custom log table schema:
Column Type
TimeGenerated datetime
Name string
TraceId string
TraceId string
SpanId string
ParentId string
StartTime datetime
EndTime datetime
Attributes dynamic

Getting started

Scope decleration:

using OpenTelemetry;
using OpenTelemetry.Exporter.AzureMonitorLogs;
using OpenTelemetry.Trace;

Data collector api:

Adding azure log analytics exporter:
using var tracerProvider = Sdk.CreateTracerProviderBuilder()
.AddAzureMonitorLogsExporter(o =>
{
    o.WorkspaceId = //Workspace immutable id.
    o.SharedKey = //workspace shared key, can be either primary or secondary.
    o.TableName = //destination custom log table.
})
.Build();

Ingestion api:

Adding azure log analytics exporter:
using var tracerProvider = Sdk.CreateTracerProviderBuilder()
.AddAzureMonitorLogsExporter(o =>
{
    o.WorkspaceId = //Workspace immutable id.
    o.ClientId = //Application client id.
    o.ClientSecret = //Application client secret.
    o.TenantId = //AAD Tenant id.
    o.AuthorityBaseUri = //AAD base url, for example - https://login.microsoftonline.com.
    o.Audience = //Azure Resource Manager target audience, for example - https://monitor.azure.com/.default
    o.DceUri = //dce uri, for example - https://yyyyyyy.{region}.ingest.monitor.azure.com
    o.DcrImmutableId = //dcr immutable id, for example - dcr-yyyyxxxxaaaaazzzz00000
    o.TableName = //destination custom log table.
})
.Build();

Examples:

Console application example

Product Compatible and additional computed target framework versions.
.NET net7.0 is compatible.  net7.0-android was computed.  net7.0-ios was computed.  net7.0-maccatalyst was computed.  net7.0-macos was computed.  net7.0-tvos was computed.  net7.0-windows was computed.  net8.0 was computed.  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