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

Fix for InvalidLaunchTemplateId.NotFound error #5665

Merged
merged 2 commits into from
Feb 15, 2024

Conversation

jigisha620
Copy link
Contributor

@jigisha620 jigisha620 commented Feb 14, 2024

Fixes #N/A

Description
If we delete EC2NodeClass and there is a cache eviction later, we see errors like these -
{"level":"ERROR","time":"2024-01-25T05:33:52.210Z","logger":"controller","message":"failed to delete launch template, InvalidLaunchTemplateId.NotFound: The specified launch template, with template ID lt-019c5be5798f24ca7, does not exist.\n\tstatus code: 400, request id: 86bff5c8-9bc6-485a-a5a8-1619d6c81283","commit":"7cdc79a-dirty","launch-template":"karpenter.k8s.aws/2686062690276844038"}

The fix that was added earlier to handle this scenario was checking if InvalidLaunchTemplateName.NotFoundException has occurred when it should have been checking for InvalidLaunchTemplateId.NotFound.

How was this change tested?
/karpenter snapshot

Does this change impact docs?

  • Yes, PR includes docs updates
  • Yes, issue opened: #
  • No

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

@jigisha620 jigisha620 requested a review from a team as a code owner February 14, 2024 21:35
Copy link

netlify bot commented Feb 14, 2024

Deploy Preview for karpenter-docs-prod canceled.

Name Link
🔨 Latest commit 3c0f3c5
🔍 Latest deploy log https://app.netlify.com/sites/karpenter-docs-prod/deploys/65cd469f9df3680008ca6eb3

@coveralls
Copy link

coveralls commented Feb 14, 2024

Pull Request Test Coverage Report for Build 7908508106

Details

  • 0 of 1 (100.0%) changed or added relevant line in 1 file are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage increased (+0.02%) to 82.514%

Totals Coverage Status
Change from base Build 7908497117: 0.02%
Covered Lines: 5016
Relevant Lines: 6079

💛 - Coveralls

Copy link
Contributor Author

@jigisha620 jigisha620 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/karpenter snapshot

@jigisha620 jigisha620 changed the title Added InvalidLaunchTemplateId Not Found error Fix for InvalidLaunchTemplateId.NotFound error Feb 14, 2024
Copy link
Contributor

Snapshot successfully published to oci://021119463062.dkr.ecr.us-east-1.amazonaws.com/karpenter/snapshot/karpenter:v0-9d06b313568f6e0eb305cb06fc9bdc63549b0cc8.
To install you must login to the ECR repo with an AWS account:

aws ecr get-login-password --region us-east-1 | docker login --username AWS --password-stdin 021119463062.dkr.ecr.us-east-1.amazonaws.com

Copy link
Contributor

@jonathan-innis jonathan-innis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@jigisha620 jigisha620 merged commit fe3aeac into aws:main Feb 15, 2024
16 checks passed
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.

None yet

3 participants