Open ashutosh16 opened 1 week ago
I agree that it shouldn't crash, but I do wonder what the behavior should be. I think the lack of configuration (i.e. rollingSync: {}
) should make the ApplicationSet controller "fall back" as if progressive syncs weren't enabled.
The strategy is configured as
strategy:
type: RollingSync
rollingSync: {}
Probably the behavior should be the same as one step that does not match any applications.
strategy:
type: RollingSync
rollingSync:
steps:
- matchExpressions:
- key: foo
operator: In
values:
- a-value-that-does-not-match-anything
Not sure what happens when applications are not selected by any matchExpression, are they updated last? If so, it ends up to the same behavior @christianh814 described, while following the specified type: RollingSync
codepath.
Unless there is an existing validation that all applications must be part of at least one step, then I think this behavior makes sense.
The doc should be updated to explain the behavior when an app is not selected in any steps.
In applicationset, when using the rollingSync strategy, the user accidentally removed the steps that caused the controller start crashing.
To Reproduce https://argo-cd.readthedocs.io/en/stable/operator-manual/applicationset/Progressive-Syncs/#rollingsync
set the strategy: rollingSync: {}
Expected behavior The controller errored out the applicationset when incorrect configuration issue but the controller shouldn't never crash due to misconfiguration.
Logs