Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

(CloudWatch Insights): amazon-cloudwatch-observability already exists #1009

Open
pennywisdom opened this issue Jun 7, 2024 · 0 comments
Open
Labels
bug Something isn't working

Comments

@pennywisdom
Copy link
Contributor

pennywisdom commented Jun 7, 2024

Describe the bug

Upgrading from v1.13.1 to v1.14.1 fails with "amazon-cloudwatch-observability already exists" even when the implementation has not changed.

Expected Behavior

No change.

Current Behavior

Between 1.13.1 and 1.14.1 the logical id is changing from CloudWatchInsightsAddon to amazoncloudwatchobservabilityaddOn. As per the following documentation for CDK (see Logical ID stability at the foot of this page - https://docs.aws.amazon.com/cdk/v2/guide/identifiers.html):

Avoid changing the logical ID of a resource after it has been created. AWS CloudFormation identifies resources by their logical ID. Therefore, if you change the logical ID of a resource, AWS CloudFormation creates a new resource with the new logical ID, then deletes the existing one.

This is the issue we are experiencing, the previous object with the CloudWatchInsightsAddon is being deleted after the newer amazoncloudwatchobservabilityaddOn but both have the same physical id.

So when updating CDK even though a diff wants to destroy the previous one, the create is happening before the destroy as you would typically expect, but because physical id already exists then the error occurs

Reproduction Steps

create a cluster using 1.13.1 and add the cloudwatch insights addon using the default props e.g. const addOn = new blueprints.addons.CloudWatchInsights(). Then upgrade to 1.14.1.

Possible Solution

change the default props add on name or add a warning.

Additional Information/Context

No response

CDK CLI Version

2.133.0

EKS Blueprints Version

v1.14.1

Node.js Version

18

Environment details (OS name and version, etc.)

container - redhat/ubi8-minimal:8.8

Other information

No response

@pennywisdom pennywisdom added the bug Something isn't working label Jun 7, 2024
@pennywisdom pennywisdom changed the title (module name): (short issue description) (CloudWatch Insights): amazon-cloudwatch-observability already exists Jun 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant