[release-1.10] fix: do not delete disabled resources [RHDHBUGS-2781] - #2863
Conversation
* do not delete disabled resources * do not delete disabled resources --------- Co-authored-by: Armel Soro <asoro@redhat.com>
Code Review by Qodo
Context used✅ Compliance rules (platform):
18 rules 1. Docs contradict monitoring behavior
|
|
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## release-1.10 #2863 +/- ##
================================================
- Coverage 61.18% 61.05% -0.13%
================================================
Files 37 37
Lines 2128 2098 -30
================================================
- Hits 1302 1281 -21
+ Misses 692 683 -9
Partials 134 134
Flags with carried forward coverage won't be shown. Click here to find out more.
🚀 New features to boost your workflow:
|
Review Summary by QodoPrevent automatic deletion of disabled resources in CR
WalkthroughsDescription• Remove automatic deletion of disabled resources when features are disabled • Resources now persist when corresponding CR features are disabled • Eliminates unintended cleanup of user-created resources • Simplifies monitoring and database cleanup logic Diagramflowchart LR
A["Disabled Features in CR"] -->|Previously| B["Auto-delete Resources"]
A -->|Now| C["Preserve Resources"]
B --> D["User Data Loss"]
C --> E["User Control"]
File Changes1. internal/controller/backstage_controller.go
|



Manual cherry-pick of #2733
ref: https://redhat.atlassian.net/browse/RHDHBUGS-2781