Refactor the operator reconcile
method to make it non-blocking
#15127
Labels
area/che-operator
Issues and PRs related to Eclipse Che Kubernetes Operator
kind/technical-debt
Technical debt issue
severity/P1
Has a major impact to usage or development of the system.
Milestone
Is your task related to a problem? Please describe.
Currently the main
reconcile
method of the Che operator contains synchronous calls that wait for the end of the deployment of some K8S object, before continuing the process. This is a bad design, since it blocks the operator loop, and prevent the operator to take in account any other change event in the Custom Resource that might occur in the meantime.Describe the solution you'd like
The reconcile logic of the operator should be non-blocking. Instead of being linear, it should be designed as a state machine, in order to allow reacting to any change event in a custom resource as soon as it happens.
Refactoring the structure of the reconcile method may also allow slicing the logic into several steps, and this would obviously make decent testing easier (see issue #15123)
The text was updated successfully, but these errors were encountered: