Skip to main content
Source: Al0070NonOtlpCollectorEndpointAnalyzer.cs

Description

Telemetry collector endpoints should use the OTLP protocol for better performance and standardization compared to legacy protocols like Zipkin or Jaeger.

Bad Code

builder.Services.AddOpenTelemetry()
    .WithTracing(t => t.AddZipkinExporter());

Good Code

builder.Services.AddOpenTelemetry()
    .WithTracing(t => t.AddOtlpExporter());

Properties

  • Category: Configuration
  • Severity: Warning
  • Enabled by default: True
  • Code fix available: False

Configuration

dotnet_diagnostic.AL0070.severity = warning