OpenTelemetry.Exporter.InfluxDB
1.0.0-alpha.5
Prefix Reserved
dotnet add package OpenTelemetry.Exporter.InfluxDB --version 1.0.0-alpha.5
NuGet\Install-Package OpenTelemetry.Exporter.InfluxDB -Version 1.0.0-alpha.5
<PackageReference Include="OpenTelemetry.Exporter.InfluxDB" Version="1.0.0-alpha.5" />
<PackageVersion Include="OpenTelemetry.Exporter.InfluxDB" Version="1.0.0-alpha.5" />
<PackageReference Include="OpenTelemetry.Exporter.InfluxDB" />
paket add OpenTelemetry.Exporter.InfluxDB --version 1.0.0-alpha.5
#r "nuget: OpenTelemetry.Exporter.InfluxDB, 1.0.0-alpha.5"
#:package OpenTelemetry.Exporter.InfluxDB@1.0.0-alpha.5
#addin nuget:?package=OpenTelemetry.Exporter.InfluxDB&version=1.0.0-alpha.5&prerelease
#tool nuget:?package=OpenTelemetry.Exporter.InfluxDB&version=1.0.0-alpha.5&prerelease
InfluxDB Exporter for OpenTelemetry .NET
| Status | |
|---|---|
| Stability | Alpha |
| Code Owners | @havret |
The InfluxDB exporter converts OpenTelemetry metrics into the InfluxDB model following the OpenTelemetry->InfluxDB conversion schema.
This exporter can be used with InfluxDB 2.x and InfluxDB 1.8+ (see details).
Prerequisite
Step 1: Install Package
dotnet add package --prerelease OpenTelemetry.Exporter.InfluxDB
Step 2: Configure OpenTelemetry MeterProvider
- When using the OpenTelemetry.Extensions.Hosting package on .NET 6.0+:
services.AddOpenTelemetry()
.WithMetrics(builder => builder
.AddInfluxDBMetricsExporter(options =>
{
options.Org = "org";
options.Bucket = "bucket";
options.Token = "token";
options.Endpoint = new Uri("http://localhost:8086");
options.MetricsSchema = MetricsSchema.TelegrafPrometheusV2;
}));
Or configure directly:
Call the
MeterProviderBuilder.AddInfluxDBMetricsExporterextension to register the Prometheus exporter.
var meterProvider = Sdk.CreateMeterProviderBuilder()
.AddInfluxDBMetricsExporter(options =>
{
options.Org = "org";
options.Bucket = "bucket";
options.Token = "token";
options.Endpoint = new Uri("http://localhost:8086");
options.MetricsSchema = MetricsSchema.TelegrafPrometheusV2;
})
.Build();
builder.Services.AddSingleton(meterProvider);
Configuration
You can configure the InfluxDBMetricsExporter through
InfluxDBMetricsExporterOptions.
Endpoint
HTTP/S destination for the line protocol.
Org
The name of the InfluxDB organization that owns the destination bucket.
Bucket
The name of the InfluxDB bucket to which signals will be written.
Token
The authentication token for InfluxDB.
MetricsSchema
The chosen metrics schema to write. Default value is
MetricsSchema.TelegrafPrometheusV1.
FlushInterval
The time to wait at most (in milliseconds) with the write. Default value is 1000.
InfluxDB 1.8 API Compatibility
InfluxDB 1.8.0 introduced forward compatibility APIs for InfluxDB 2.0, allowing you to easily transition from InfluxDB 1.x to InfluxDB 2.0 Cloud or open source.
Here's a summary of the client API usage differences:
- Token
Use the format username:password for an authentication token, e.g.,
my-user:my-password. If the server doesn't require authentication,
use an empty string ("").
- Org
The organization parameter is not used in InfluxDB 1.8. Use a hyphen ("-") where necessary.
- Bucket
Use the format database/retention-policy where a bucket is required. If the
default retention policy should be used, skip the retention policy.
Examples: telegraf/autogen, telegraf.
When using InfluxDB 1.8, modify the AddInfluxDBMetricsExporter options accordingly:
services.AddOpenTelemetry()
.WithMetrics(builder => builder
.AddInfluxDBMetricsExporter(options =>
{
options.Org = "-";
options.Bucket = "telegraf/autogen";
options.Token = "my-user:my-password";
options.Endpoint = new Uri("http://localhost:8086");
options.MetricsSchema = MetricsSchema.TelegrafPrometheusV2;
}));
Troubleshooting
This component uses an EventSource with the name "OpenTelemetry-Exporter-InfluxDB" for its internal logging. Please refer to SDK troubleshooting for instructions on seeing these internal logs.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net5.0 was computed. net5.0-windows was computed. net6.0 was computed. net6.0-android was computed. net6.0-ios was computed. net6.0-maccatalyst was computed. net6.0-macos was computed. net6.0-tvos was computed. net6.0-windows was computed. net7.0 was computed. 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 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. |
| .NET Core | netcoreapp2.0 was computed. netcoreapp2.1 was computed. netcoreapp2.2 was computed. netcoreapp3.0 was computed. netcoreapp3.1 was computed. |
| .NET Standard | netstandard2.0 is compatible. netstandard2.1 was computed. |
| .NET Framework | net461 was computed. net462 was computed. net463 was computed. net47 was computed. net471 was computed. net472 was computed. net48 was computed. net481 was computed. |
| MonoAndroid | monoandroid was computed. |
| MonoMac | monomac was computed. |
| MonoTouch | monotouch was computed. |
| Tizen | tizen40 was computed. tizen60 was computed. |
| Xamarin.iOS | xamarinios was computed. |
| Xamarin.Mac | xamarinmac was computed. |
| Xamarin.TVOS | xamarintvos was computed. |
| Xamarin.WatchOS | xamarinwatchos was computed. |
-
.NETStandard 2.0
- InfluxDB.Client (>= 4.18.0)
- OpenTelemetry (>= 1.13.1 && < 2.0.0)
- System.Text.Json (>= 8.0.5)
-
net8.0
- InfluxDB.Client (>= 4.18.0)
- OpenTelemetry (>= 1.13.1 && < 2.0.0)
- System.Text.Json (>= 8.0.5)
NuGet packages (2)
Showing the top 2 NuGet packages that depend on OpenTelemetry.Exporter.InfluxDB:
| Package | Downloads |
|---|---|
|
JF91.OpenTelemetry
Integrate OpenTelemetry into your ASP.NET Web API using appsettings.json |
|
|
telemetra.monitoring
Telemetra Monitoring SDK provides a unified, extensible, and production-ready observability solution for .NET applications. It enables seamless collection and export of traces, metrics, and logs to multiple backends (OTLP, Jaeger, Grafana, Sentry, Tempo, Alloy, Console, Prometheus, Zipkin) with advanced configuration, business insights, and enterprise features. |
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 1.0.0-alpha.5 | 112 | 10/23/2025 |
| 1.0.0-alpha.4 | 19,602 | 10/2/2024 |
| 1.0.0-alpha.3 | 22,197 | 10/13/2023 |
| 1.0.0-alpha.2 | 1,424 | 6/20/2023 |
| 1.0.0-alpha.1 | 210 | 5/19/2023 |