Skip to content

Conversation

@singholt
Copy link
Contributor

@singholt singholt commented Aug 27, 2025

Summary

This PR updates the list of docker-remote-api capabilities that the agent reports to ECS during instance registration.

Every new Docker server release brings in new client API versions that it can support. Over time, the number of supported Docker API versions has grown significantly - currently at about 27. We have a limit on the number of capabilities that agent can send during instance registration, hence we stop reporting v1.33+. We are also going to stop reporting 1.26, 1.27, and 1.31, as these are unused. We need to continue reporting all other versions to support legacy ECS back-end logic.

This change give us a headroom of about 15 capabilities, while also stopping addition of new Docker remote API capabilities for every new Docker server version.

Implementation details

Updated the agent capability parsing to exclude unnwanted docker-remote-api capabilities.

Testing

New tests cover the changes: yes

I manually verified that the container instances no longer report the excluded capabilities.

aws ecs describe-container-instances --cluster {cluster-name} --container-instances {instance-id} --query 'containerInstances[0].attributes[?starts_with(name, `com.amazonaws.ecs.capability.docker`)]' --output table --region us-west-2
---------------------------------------------------------
|              DescribeContainerInstances               |
+-------------------------------------------------------+
|                         name                          |
+-------------------------------------------------------+
|  com.amazonaws.ecs.capability.docker-remote-api.1.30  |
|  com.amazonaws.ecs.capability.docker-remote-api.1.32  |
|  com.amazonaws.ecs.capability.docker-remote-api.1.24  |
|  com.amazonaws.ecs.capability.docker-remote-api.1.25  |
|  com.amazonaws.ecs.capability.docker-remote-api.1.28  |
|  com.amazonaws.ecs.capability.docker-remote-api.1.29  |
|  com.amazonaws.ecs.capability.docker-remote-api.1.20  |
|  com.amazonaws.ecs.capability.docker-remote-api.1.21  |
|  com.amazonaws.ecs.capability.docker-remote-api.1.22  |
|  com.amazonaws.ecs.capability.docker-remote-api.1.23  |
|  com.amazonaws.ecs.capability.docker-remote-api.1.17  |
|  com.amazonaws.ecs.capability.docker-remote-api.1.18  |
|  com.amazonaws.ecs.capability.docker-remote-api.1.19  |
+-------------------------------------------------------+

I also verified that there are no customers (across all AWS regions) that rely on these unwanted docker-remote-api capabilities, via ECS task placement constraints.

Description for the changelog

Enhancement: Remove unwanted docker-remote-api capabilities

Additional Information

Does this PR include breaking model changes? If so, Have you added transformation functions? No

Does this PR include the addition of new environment variables in the README? No, I also verified that there's no mention of docker-remote-api capabilities in the README and ECS public docs.

Licensing

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

@singholt singholt changed the base branch from master to dev August 27, 2025 01:53
@singholt singholt force-pushed the docker-remote-caps branch 3 times, most recently from 9ff2d74 to bdc6aae Compare August 27, 2025 02:17
@singholt singholt force-pushed the docker-remote-caps branch from bdc6aae to d80f270 Compare August 27, 2025 03:07
@singholt singholt changed the title wip: docker remote caps Update the list of docker-remote-api capabilities Aug 27, 2025
@singholt singholt marked this pull request as ready for review August 27, 2025 16:58
@singholt singholt requested a review from a team as a code owner August 27, 2025 16:58
@singholt singholt merged commit 813fa2e into aws:dev Aug 28, 2025
40 checks passed
@singholt singholt deleted the docker-remote-caps branch August 28, 2025 23:15
@danehlim danehlim mentioned this pull request Sep 3, 2025
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.

4 participants