@opentelemetry/resource-detector-aws
TypeScript icon, indicating that this package has built-in type declarations

1.4.1 • Public • Published

OpenTelemetry Resource Detector for AWS

NPM Published Version Apache License

component owners: @carolabadeer

Resource detector for Amazon Web Services.

Status

Maturity Component Owner Compatibility
Stable @carolabadeer API 1.0+
SDK 1.0+

Installation

npm install --save @opentelemetry/resource-detector-aws

Usage

import { detectResources } from '@opentelemetry/resources';
import { awsEc2Detector } from '@opentelemetry/resource-detector-aws'
const resource = await detectResources({
   detectors: [awsEc2Detector],
})

const tracerProvider = new NodeTracerProvider({ resource });

Available detectors

  • awsBeanstalkDetector: Populates service for processes running on AWS Elastic Beanstalk
  • awsEc2Detector: Populates cloud and host for processes running on Amazon EC2, including abstractions such as ECS on EC2. Notably, it does not populate anything on AWS Fargate
  • awsEcsDetector: Populates container for containers running on Amazon ECS
  • awsEksDetector: Populates container and k8s.cluster_name for containers running on Amazon EKS
    • k8s.cluster_name is not always available depending on the configuration of CloudWatch monitoring for the EKS cluster
  • awsLambdaDetector: Populates faas and cloud for functions running on AWS Lambda
    • faas.id is currently not populated as it is not provided by the runtime at startup

Useful links

License

Apache 2.0 - See LICENSE for more information.

Package Sidebar

Install

npm i @opentelemetry/resource-detector-aws

Weekly Downloads

502,339

Version

1.4.1

License

Apache-2.0

Unpacked Size

101 kB

Total Files

24

Last publish

Collaborators

  • pichlermarc
  • bogdandrutu
  • dyladan