fix: requeue at dependency interval for missing object refs - #1577
Open
Bisman-Singh wants to merge 2 commits into
Open
fix: requeue at dependency interval for missing object refs#1577Bisman-Singh wants to merge 2 commits into
Bisman-Singh wants to merge 2 commits into
Conversation
When the Source object referenced by a HelmRelease or a non-optional valuesFrom ConfigMap/Secret does not exist yet, requeue at the --requeue-dependency interval instead of retrying with exponential backoff. This is consistent with how not ready dependencies and sources are already handled, and speeds up bootstrap ordering when the referenced objects are created shortly after the HelmRelease. Part of fluxcd/flux2#5809 Signed-off-by: Bisman-Singh <bismanmadaan1@gmail.com>
Bisman-Singh
marked this pull request as ready for review
September 1, 2026 07:11
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.
Part of fluxcd/flux2#5809
When the Source object referenced by a HelmRelease (
chartRefor theHelmChartfrom status) or a non-optionalvaluesFromConfigMap/Secret does not exist yet, the controller returned the raw error, putting the object on controller-runtime exponential backoff. This is inconsistent with how not ready dependencies, not ready sources and missing artifact files are handled, all of which requeue at the--requeue-dependencyinterval, and it delays bootstrap ordering when the referenced objects are created shortly after the HelmRelease (e.g. via a ResourceSet).This change routes the two not-found paths through the existing
errWaitForDependencyhandling:getSourcereturning a NotFound error now requeues at--requeue-dependency(Ready=False withArtifactFailedReasonis still recorded).chartutil.ChartValuesFromReferencesfailing withErrResourceNotFoundnow requeues at--requeue-dependency(Ready=False withValuesErrorand the warning event are still recorded).Other errors on these paths (ACL denied, key-not-found in an existing values reference, transient API errors) keep their current behavior.
Tests: new
waits for HelmChart to existandwaits for values reference to existsubtests plus an updatedhandles ChartRef get failuresubtest assert the dependency-interval requeue; negative-path subtests pin generic Get errors and key-not-found to the backoff path. All were verified to fail against the unfixed code.Signed-off-by: Bisman-Singh bismanmadaan1@gmail.com