Current behaviour
When removing a backend usage and the limits of an application plan that refers to the backend at the same time, the Operator fails to reconcile the Product.
Steps to reproduce:
- Create 2 Backends: Backend A and Backend B.
- Create 1 Product which contains usages to Backend A and Backend B as well as an Application plan with limits related to Backend B. See attachment.
- Wait for the Operator to sync all resources.
- Update the Product CR as follows with a single update:
- remove `spec.backendUsages.backend_b_123`
- set `spec.applicationPlans.plan_foo_bar.limits` to `[]` (an empty list)
- The Product CR will fail to sync with the following error:
"message": "Task failed SyncApplicationPlans: Error sync product [test_product_123] plan [plan_foo_bar]: Task failed SyncLimits: application plan [plan_foo_bar] delete limit: error calling 3scale system - reason: {\"status\":\"Not found\"} - code: 404"
Expected behaviour:
Be able to remove both references:
- backend usage
- limits of the application plan related to backend
at the same time.
Dev Notes
Please see this comment
- blocks
-
THREESCALE-11554 3scale operator fails to reconcile a Product CR when a backend reference is removed from usages and application plan limit is removed too
- To Develop
- is related to
-
THREESCALE-11541 Set annotation Managed-By Operator on all api calls
- To Test (QE)