For the complete documentation index, see llms.txt. This page is also available as Markdown.
Page cover

"Serverless"

This page describes getting data in from popular "Serverless" offerings.

ECS Fargate

IAM Policies and Roles

Create IAM Policy and Roles:

Create SSM

Example Config:

extensions:
  health_check:
receivers:
  otlp:
    protocols:
      grpc:
        endpoint: 0.0.0.0:4317
      http:
        endpoint: 0.0.0.0:4318
  awsecscontainermetrics:

processors:
  batch:
  resourcedetection:
    detectors:
      - env
      - system
      - ecs
      - ec2
  filter:
    metrics:
      include:
        match_type: strict
        metric_names:
          - ecs.task.memory.reserved
          - ecs.task.memory.utilized
          - ecs.task.cpu.reserved
          - ecs.task.cpu.utilized
          - ecs.task.network.rate.rx
          - ecs.task.network.rate.tx
          - ecs.task.storage.read_bytes
          - ecs.task.storage.write_bytes
          - container.duration

exporters:
  otlphttp/example:
    endpoint: "{INTAKE}"
    headers:
      Authorization: "Bearer {AUTH_TOKEN}"

service:
  pipelines:
    metrics/application:
      receivers: [otlp]
      processors: [resourcedetection, batch]
      exporters: [otlphttp/example]
    metrics:
      receivers: [awsecscontainermetrics]
      processors: [filter]
      exporters: [otlphttp/example]
    logs:
      receivers: [otlp]
      processors: [resourcedetection, batch]
      exporters: [otlphttp/example]
    traces:
      receivers: [otlp]
      processors: [resourcedetection, batch]
      exporters: [otlphttp/example]

  extensions: [health_check]

Task Definition Specifics

Task Roles:

ADOT Container:

ADOT Environment Variables (Config):

AWS Lambda

Add Layer with ARN (python example: arn:aws:lambda:us-west-2:901920570463:layer:aws-otel-python-amd64-ver-1-25-0:1.). Language specific instructions: https://aws-otel.github.io/docs/getting-started/lambda#getting-started-with-aws-lambda-layers

Add custom configuration (in same folder) to bundle or S3: https://aws-otel.github.io/docs/getting-started/lambda#custom-configuration-for-the-adot-collector-on-lambda

Add env variables. Example with S3 config (for s3 , lambda iam role needs access to bucket)

Last updated