Skip to content

Add ECS Fargate ephemeral storage metrics from Task Metadata Endpoint V4#3166

Open
neilkuan wants to merge 1 commit intoaws-observability:mainfrom
neilkuan:feat/ecs-ephemeral-storage-metrics
Open

Add ECS Fargate ephemeral storage metrics from Task Metadata Endpoint V4#3166
neilkuan wants to merge 1 commit intoaws-observability:mainfrom
neilkuan:feat/ecs-ephemeral-storage-metrics

Conversation

@neilkuan
Copy link
Copy Markdown

@neilkuan neilkuan commented Mar 6, 2026

Summary

Vendor patch to add support for EphemeralStorageMetrics from the ECS Task Metadata Endpoint V4.

This is based on upstream commit 0cf514fa0ab3 (open-telemetry/opentelemetry-collector-contrib#46414).

Changes

Patched the following files in vendor/:

  • internal/aws/ecsutil/metadata.go — Added EphemeralStorageMetrics struct and field to TaskMetadata
  • receiver/awsecscontainermetricsreceiver/internal/awsecscontainermetrics/ecs_metrics.go — Added EphemeralStorageUtilized and EphemeralStorageReserved fields to ECSMetrics
  • receiver/awsecscontainermetricsreceiver/internal/awsecscontainermetrics/accumulator.go — Populate ephemeral storage metrics from task metadata
  • receiver/awsecscontainermetricsreceiver/internal/awsecscontainermetrics/constant.go — Added metric attribute constants; fixed memory unit from Megabytes to MiB
  • receiver/awsecscontainermetricsreceiver/internal/awsecscontainermetrics/translator.go — Emit ephemeral storage metrics at task level; applied MiB unit fix for memory metrics

New Metrics

Metric Name Unit Description
container.ephemeral_storage.utilized MiB Ephemeral storage used by the Fargate task
container.ephemeral_storage.reserved MiB Ephemeral storage reserved for the Fargate task

These metrics are only available at the task level and only for Fargate launch type.

Testing

  • Built and verified locally (go build ./cmd/awscollector)
  • Docker image built and published: ghcr.io/neilkuan/aws-otel-collector/aws-otel-collector:fixed

Vendor patch from opentelemetry-collector-contrib commit 0cf514fa0ab3.

This adds support for EphemeralStorageMetrics from the ECS Task Metadata
Endpoint V4, exposing two new task-level metrics:
- container.ephemeral_storage.utilized (MiB)
- container.ephemeral_storage.reserved (MiB)

These metrics represent the shared ephemeral storage usage for Fargate tasks.

Also fixes memory metrics unit from 'Megabytes' to 'MiB' for consistency.

Upstream PR: open-telemetry/opentelemetry-collector-contrib#46414
@neilkuan neilkuan requested a review from a team as a code owner March 6, 2026 10:02
@neilkuan
Copy link
Copy Markdown
Author

neilkuan commented Mar 7, 2026

Hi @Kausik-A could you take a look this PR? thank you.

@github-actions
Copy link
Copy Markdown
Contributor

This PR is stale because it has been open 30 days with no activity.

@github-actions github-actions Bot added the stale label Apr 12, 2026
@neilkuan
Copy link
Copy Markdown
Author

Hi @Kausik-A could you take a look this PR? thank you.

1 similar comment
@stp-github-automation
Copy link
Copy Markdown

Hi @Kausik-A could you take a look this PR? thank you.

@github-actions github-actions Bot removed the stale label Apr 19, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants