Don't set compressionstatus and validation status in backupVO and bac…#13661
Don't set compressionstatus and validation status in backupVO and bac…#13661abh1sar wants to merge 2 commits into
Conversation
…kupsResponse for non-kboss providers. These columns are hidden in UI if they are not set.
There was a problem hiding this comment.
Pull request overview
This PR addresses #13660 by preventing KBOSS-specific backup fields (compression/validation status) from being populated and shown for non-KBOSS backup providers, reducing misleading UI output.
Changes:
- UI: Hide
compressionstatus/validationstatuscolumns for VM backups unless the VM backup provider iskboss. - UI (generic list view): For
listBackups, automatically drop KBOSS-only columns when the returned backup rows don’t include those fields. - Server: Only set
compressionStatus/validationStatus(anduncompressedSize) inBackupResponsewhen the underlyingBackuphas non-null values; stop defaulting these fields inBackupVO, and explicitly set defaults only for KBOSS-created backups.
Reviewed changes
Copilot reviewed 5 out of 5 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| ui/src/views/compute/InstanceTab.vue | Conditionally includes KBOSS-only backup columns based on dataResource.backupprovider. |
| ui/src/views/AutogenView.vue | Removes KBOSS-only columns for listBackups when the returned items don’t contain KBOSS field data. |
| server/src/main/java/org/apache/cloudstack/backup/BackupManagerImpl.java | Avoids emitting compression/validation fields in API responses when they are null in the backup entity. |
| plugins/backup/kboss/src/main/java/org/apache/cloudstack/backup/KbossBackupProvider.java | Explicitly initializes compression/validation statuses for KBOSS backups at creation time. |
| engine/schema/src/main/java/org/apache/cloudstack/backup/BackupVO.java | Stops default-initializing compression/validation statuses for all backups; makes them explicitly provided when needed. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
@winterhazel @weizhouapache can this be considered for 4.23 please? |
|
@blueorangutan package |
|
@abh1sar a [SL] Jenkins job has been kicked to build packages. It will be bundled with no SystemVM templates. I'll keep you posted as I make progress. |
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #13661 +/- ##
============================================
- Coverage 19.64% 19.64% -0.01%
Complexity 19789 19789
============================================
Files 6368 6368
Lines 575109 575116 +7
Branches 70371 70375 +4
============================================
- Hits 112994 112987 -7
- Misses 449829 449842 +13
- Partials 12286 12287 +1
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
Asking @JoaoJandre's review on this one. I think we can include it. |
|
@abh1sar @JoaoJandre I think hiding these two columns when not using the KBOSS plugin is ok. A single suggestion: when using KBOSS, isn't it better to display |
|
Packaging result [SF]: ✔️ el8 ✔️ el9 ✔️ el10 ✖️ debian ✔️ suse15. SL-JID 18635 |
|
🔴 Test Coverage Grade:
|
| Metric | Value |
|---|---|
| Line coverage | 24.50% |
| Branch coverage | 18.66% |
Grade Scale
| Grade | Line Coverage | Meaning |
|---|---|---|
| 🟢 A | ≥ 80% | Excellent - this code sleeps well at night 😴 |
| 🟡 B | 60-79% | Good - almost there, don't stop now 😉 |
| 🟠 C | 40-59% | Acceptable - your code is wearing a seatbelt, but no airbags 😬 |
| 🔴 D | 20-39% | Marginal - boldly shipping where no test has gone before 🖖 |
| ⛔ F | < 20% | Failing - tests? what tests? 🔥 |
Branch coverage is shown as a secondary signal. Grade is determined by line coverage.
View full Actions run
…t and if column is being shown
|
|
@blueorangutan package |
|
@abh1sar a [SL] Jenkins job has been kicked to build packages. It will be bundled with no SystemVM templates. I'll keep you posted as I make progress. |




…kupsResponse for non-kboss providers.
These columns are hidden in UI if they are not set.
Description
This PR fixes #13660
Types of changes
Feature/Enhancement Scale or Bug Severity
Feature/Enhancement Scale
Bug Severity
Screenshots (if appropriate):
How Has This Been Tested?
Created an Env with NAS plugin enabled.
Before fix:
After fix:
Removed the Nas offering and assigned the VM to a Kboss offering and took another backup.
The fields are visible now. The older NAS backups show the fields as empty instead of
UncompressedHow did you try to break this feature and the system with this change?