There are concurrency concerns when reconciling launch resources: if two launches level-changes are processed concurrently, then multiple helm commands may be issued for the same deployment, possibly resulting in an unexpected state. The easiest way to address this is to elect a single controller as a leader, and have only that instance process requests.
A more complex example may involve electing a leader per-launch, so that only a single controller manages a particular helm deployment.
Concurrency as a whole should be further investigated with regard to how the reconciler works. Can the reconciler itself be invoked concurrently? If so, other mechanisms should be employed to prevent concurrent requests to helm.
There are concurrency concerns when reconciling
launchresources: if twolauncheslevel-changes are processed concurrently, then multiplehelmcommands may be issued for the same deployment, possibly resulting in an unexpected state. The easiest way to address this is to elect a single controller as a leader, and have only that instance process requests.A more complex example may involve electing a leader per-launch, so that only a single controller manages a particular helm deployment.
Concurrency as a whole should be further investigated with regard to how the reconciler works. Can the reconciler itself be invoked concurrently? If so, other mechanisms should be employed to prevent concurrent requests to helm.