Files
floci/compatibility-tests/sdk-test-java/src
Hector Ventura 1eb402d623 fix(ec2): keep tags in the region of the resource they label (#5973)
* fix(ec2): keep tags in the region of the resource they label

DescribeTags listed every region's tags because the tag store was keyed by
the bare resource id. Tags are now stored per region, so DescribeTags,
DeleteTags, CreateTags and the aws:ResourceTag IAM condition only see the
request region's tags. Each side of a cross-region transit gateway or VPC
peering connection keeps its own tags in its own region.

Tags stored by bare id are moved under their resource's region at startup,
for every account; a tag whose resource no region holds is dropped.

DescribeTags now reports image, volume, snapshot, network-acl,
vpc-peering-connection and spot-instances-request instead of "unknown".
Tags given when a volume or peering connection is created reach the store,
and DescribeVolumes, DescribeSnapshots and DescribeSpotInstanceRequests show
later CreateTags and DeleteTags changes.

Signed-off-by: Hector Ventura <hectorvent@gmail.com>

* fix(ec2): remove tags with their resource and keep node and catalog AMI tags on upgrade

Deleting a volume (directly or as a delete-on-termination volume of a
terminated instance), a snapshot with its image or a VPC peering connection,
and pruning a terminated instance, now removes the resource's tags, both
peering sides included.

The startup migration no longer drops tags it cannot place in a store: a
catalog AMI's tags move to the default region, and an instance's are kept
until its EKS node is found in a region, which then claims them.

Signed-off-by: Hector Ventura <hectorvent@gmail.com>

* fix(ec2): file a cluster node's legacy tags under its own region

A region-less findInstanceById reaches the EKS provider, which answers from any region, so the claim moved the node's legacy tags under a null region where DescribeTags never finds them. The claim now uses the instance's own region, and with no region known it reads the legacy tags in place for a regional lookup to claim.

Signed-off-by: Hector Ventura <hectorvent@gmail.com>

* fix(ec2): pass the region in the query GET resource-tag stub

Signed-off-by: Hector Ventura <hectorvent@gmail.com>

---------

Signed-off-by: Hector Ventura <hectorvent@gmail.com>
2026-10-19 19:13:38 -04:00
..