aws / aws/containers-roadmap

[ECS] [request]: Expose container memory reservation in the metadata stats endpoint

Open
#1,893 0 comments 2 reactions 0 assignees View on GitHub
ECS Proposed
Dominant language
Shell
Stars
5.4k
Forks
334
PR merge metrics
No merged PRs in 30d

Description

### Community Note

* Please vote on this issue by adding a 👍 [reaction](https://blog.github.com/2016-03-10-add-reactions-to-pull-requests-issues-and-comments/) to the original issue to help the community and maintainers prioritize this request
* Please do not leave "+1" or "me too" comments, they generate extra noise for issue followers and do not help prioritize the request
* If you are interested in working on this issue or have submitted a pull request, please leave a comment

**Tell us about your request**
Please expose the container memory reservation in the container stats endpoint

**Which service(s) is this request for?**
ECS (EC2)

**Tell us about the problem you're trying to solve. What are you trying to do, and why is it hard?**
I am trying to tune the resource allocation of our ECS deployments. To do this, I need to understand resource consumption, any limits and any reservations which are configured. Currently (unless I'm mistaken) the memory reservation for a container in a task is only available either via `docker inspect` under `MemoryReservation` or in the memory cgroup settings. It would be much more convenient to have this information available alongside the other container statistics in the stats endpoint.

**Are you currently working around this issue?**
We are using the cloudwatch `MemoryUtilization` and `CPUUtilization` metrics for ECS services, but these do not go down to container level (container insights probably does - I haven't checked yet). We are also running telegraf as a sidecar in each ECS task to expose the task container stats to Prometheus, which allows us to track resource usage per-container (and limits per-container).

Contributor guide

Open the contributing guide

Research direction

No repository file, test, or implementation entry point is identified. Start by confirming the ECS (EC2) container stats endpoint and how Docker's MemoryReservation or cgroup value maps to the requested field; done means that reservation is exposed alongside the existing per-container statistics.

Written by the indexing model from the issue text.

Assessment

Tech stack
aws, docker, prometheus
Domain
cloud, observability
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
28/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.