K8SPG-999: Fix dropping multiple custom extensions#1539
Open
matan77 wants to merge 4 commits intopercona:mainfrom
Open
K8SPG-999: Fix dropping multiple custom extensions#1539matan77 wants to merge 4 commits intopercona:mainfrom
matan77 wants to merge 4 commits intopercona:mainfrom
Conversation
egegunes
requested changes
Apr 6, 2026
|
|
||
| log.V(1).Info("extension was disabled ", "extensionName", extensionName) | ||
| if err != nil { | ||
| return errors.Wrap(err, "custom extension deletion") |
Contributor
There was a problem hiding this comment.
Suggested change
| return errors.Wrap(err, "custom extension deletion") | |
| return errors.Wrap(err, "drop extension") |
Author
There was a problem hiding this comment.
I think drop custom extension is a little bit better for the error to be more verbose
Author
|
made tha change |
egegunes
approved these changes
Apr 8, 2026
Collaborator
commit: f7654e5 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
CHANGE DESCRIPTION
Problem:
The
disableCustomExtensionsInDB()function exits prematurely when deleting multiple custom extensions because thereturnstatement was inside the loop. Only the first extension is removed, leaving others installed and causing inconsistencies between the CR spec and the actual database state.Cause:
The loop iterating over
customExtensionsForDeletioncontained areturnstatement, which caused early exit before all extensions could be processed.Solution:
Moved the
returnstatement outside the loop and restructured error handling to ensure all extensions are processed before returning. Added logging for each successfully disabled extension.CHECKLIST
Jira
Needs Doc) and QA (Needs QA)?Tests
Config/Logging/Testability
Are all needed new/changed options added to default YAML files?Not RelevantAre all needed new/changed options added to theNot RelevantHelm Chart?