OpenTelemetry.Resources.AWS 1.15.0

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

AWS Resource Detectors

Status
Stability Stable
Code Owners @srprash, @normj, @lukeina2z

NuGet version badge NuGet download count badge codecov.io

Getting Started

You need to install the OpenTelemetry.Resources.AWS to be able to use the AWS Resource Detectors.

The ADOT .NET SDK supports automatically recording metadata in EC2, Elastic Beanstalk, ECS, and EKS environments.

dotnet add package OpenTelemetry.Resources.AWS

Usage

You can configure AWS resource detector to the ResourceBuilder with the following EC2 example.

using OpenTelemetry;
using OpenTelemetry.Resources;

using var tracerProvider = Sdk.CreateTracerProviderBuilder()
    .ConfigureResource(resource => resource.AddAWSEC2Detector())
    // other configurations
    .Build();

using var meterProvider = Sdk.CreateMeterProviderBuilder()
    .ConfigureResource(resource => resource.AddAWSEC2Detector())
    // other configurations
    .Build();

using var loggerFactory = LoggerFactory.Create(builder =>
{
    builder.AddOpenTelemetry(options =>
    {
        options.SetResourceBuilder(ResourceBuilder.CreateDefault().AddAWSEC2Detector());
    });
});

The resource detectors will record the following metadata based on where your application is running:

  • AWSEC2Detector: cloud provider, cloud platform, account id, cloud availability zone, host id, host type, aws region, host name.
  • AWSEBSDetector: cloud provider, cloud platform, service name, service namespace, instance id, service version.
  • AWSECSDetector: cloud provider, cloud platform, cloud resource id, account id, cloud availability zone, cloud region, container id, cluster arn, task arn, task family, task revision, launch type, container arn, log group names, log group ids, log stream names, log stream ids.
  • AWSEKSDetector: cloud provider, cloud platform, cluster name, container id.

Semantic Conventions

For an overview on Semantic Conventions, see Open Telemetery - Semantic Conventions.

While this library is intended for production use, it relies on several Semantic Conventions that are still considered Experimental, meaning they may undergo additional changes before becoming Stable. This can impact the aggregation and analysis of telemetry signals in environments with multiple applications or microservices.

For example, a microservice using an older version of the Semantic Conventions for Http Attributes may emit "http.method" with a value of GET, while a different microservice, using a new version of Semantic Convention may instead emit the GET as "http.request.method".

Future versions the OpenTelemetry.*.AWS libraries will include updates to the Semantic Convention, which may break compatibility with a previous version.

The default will remain as V1_28_0 until the next major version bump.

To opt in to automatic upgrades, you can use SemanticConventionVersion.Latest or you can specify a specific version:

using OpenTelemetry;
using OpenTelemetry.Resources;

using var tracerProvider = Sdk.CreateTracerProviderBuilder()
    .ConfigureResource(resource => resource.AddAWSEC2Detector(
        opt => {
            // pin to a specific Semantic Convention version
            opt.SemanticConventionVersion = SemanticConventionVersion.V1_29_0;
        }
    ))
    // other configurations
    .Build();

NOTE: Once a Semantic Convention becomes Stable, OpenTelemetry.*.AWS libraries will remain on that version until the next major version bump.

References

Product 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 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. 
.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 is compatible.  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. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (3)

Showing the top 3 NuGet packages that depend on OpenTelemetry.Resources.AWS:

Package Downloads
AWS.Distro.OpenTelemetry.AutoInstrumentation

Package Description

APF.Core.Clean.OpenTelemetry

This client library enables OpenTelemetry implementation in the APF services.

APF.Core.OpenTelemetry

This client library enables OpenTelemetry implementation in the APF services.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
1.15.0 19,890 1/21/2026
1.14.0 55,236 11/13/2025
1.11.1 686,597 3/6/2025
1.11.0 56,898 1/29/2025
1.10.0-rc.1 12,693 1/6/2025
1.10.0-beta.1 91,612 12/20/2024
1.5.0-beta.1 470,107 6/4/2024