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 cannot retry upgrade 1.29 to 1.30 when previous upgrade fails #406

Conversation

nvthongswansea
Copy link
Member

Change:

  • Remove the logic "if version/release is changed on resource update, derive template from version/release" in deriveK8sTemplateFromResourceData.

IF the previous upgrade (from 1.29 to 1.30) fails, the updated value of version/release is still persisted (tf provider behaviour because we don't set version/release in k8s resource READ). Hence when we re-try the upgrade, this piece of code detects no changes in version/release parameter => tf tries to get template uuid from service_template_uuid (which is just the current template of the cluster), hence no upgrade happens.

… is not changed

IF the previous upgrade (from 1.29 to 1.30) fails, the updated value of version/release is still persisted (tf provider behaviour because we don't set version/release in k8s resource READ). Hence when we re-try the upgrade, this piece of code detect no changes in version/release parameter => tf tries to get template uuid from service_template_uuid (which is just the current template of the cluster), hence no upgrade happens.
@nvthongswansea nvthongswansea requested a review from alidaw January 2, 2025 16:48
@alidaw alidaw assigned alidaw and nvthongswansea and unassigned alidaw Jan 2, 2025
@nvthongswansea nvthongswansea merged commit 5c53faa into master Jan 2, 2025
2 checks passed
nvthongswansea added a commit that referenced this pull request Jan 7, 2025
nvthongswansea added a commit that referenced this pull request Jan 7, 2025
* Revert "Fix cannot retry upgrade 1.29 to 1.30 when previous upgrade fails (#406)"

This reverts commit 5c53faa.

* ensure freshness of k8s resource after creation

* set the correct gsk version/release at resource read
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.

2 participants