Skip to content

Restrict VM snapshot without memory for VM with encrypted volumes using KvmFileBasedStorageVmSnapshotStrategy, and Use file copy for revert to snapshot from encrypted volumes (as earlier)#13228

Open
sureshanaparti wants to merge 2 commits into
apache:4.22from
shapeblue:encrypted-volumes-fixes

Conversation

@sureshanaparti
Copy link
Copy Markdown
Contributor

Description

This PR restricts VM snapshot without memory for VM with encrypted volumes using KvmFileBasedStorageVmSnapshotStrategy, and Uses file copy for revert to snapshot from encrypted volumes (as earlier).

Fixes #13188

Types of changes

  • Breaking change (fix or feature that would cause existing functionality to change)
  • New feature (non-breaking change which adds functionality)
  • Bug fix (non-breaking change which fixes an issue)
  • Enhancement (improves an existing feature and functionality)
  • Cleanup (Code refactoring and cleanup, that may add test cases)
  • Build/CI
  • Test (unit or integration test code)

Feature/Enhancement Scale or Bug Severity

Feature/Enhancement Scale

  • Major
  • Minor

Bug Severity

  • BLOCKER
  • Critical
  • Major
  • Minor
  • Trivial

Screenshots (if appropriate):

How Has This Been Tested?

How did you try to break this feature and the system with this change?

…ng KvmFileBasedStorageVmSnapshotStrategy, and Use file copy for revert to snapshot from encrypted volumes (as earlier)
@codecov
Copy link
Copy Markdown

codecov Bot commented May 25, 2026

Codecov Report

❌ Patch coverage is 12.82051% with 34 lines in your changes missing coverage. Please review.
✅ Project coverage is 17.67%. Comparing base (21b2025) to head (1f6ad6f).

Files with missing lines Patch % Lines
...e/wrapper/LibvirtRevertSnapshotCommandWrapper.java 36.36% 6 Missing and 1 partial ⚠️
...stack/engine/orchestration/VolumeOrchestrator.java 0.00% 4 Missing and 1 partial ⚠️
...napshot/KvmFileBasedStorageVmSnapshotStrategy.java 0.00% 4 Missing ⚠️
...hema/src/main/java/com/cloud/storage/VolumeVO.java 0.00% 3 Missing ⚠️
...apache/cloudstack/storage/volume/VolumeObject.java 0.00% 3 Missing ⚠️
...n/java/com/cloud/storage/VolumeApiServiceImpl.java 0.00% 3 Missing ⚠️
.../hypervisor/kvm/storage/ScaleIOStorageAdaptor.java 0.00% 2 Missing ⚠️
...n/java/com/cloud/template/TemplateManagerImpl.java 0.00% 1 Missing and 1 partial ⚠️
...a/com/cloud/vm/snapshot/VMSnapshotManagerImpl.java 0.00% 1 Missing and 1 partial ⚠️
...tack/storage/snapshot/DefaultSnapshotStrategy.java 0.00% 1 Missing ⚠️
... and 2 more
Additional details and impacted files
@@             Coverage Diff              @@
##               4.22   #13228      +/-   ##
============================================
- Coverage     17.67%   17.67%   -0.01%     
  Complexity    15792    15792              
============================================
  Files          5922     5922              
  Lines        533165   533179      +14     
  Branches      65208    65209       +1     
============================================
- Hits          94242    94241       -1     
- Misses       428276   428291      +15     
  Partials      10647    10647              
Flag Coverage Δ
uitests 3.69% <ø> (ø)
unittests 18.75% <12.82%> (-0.01%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@sureshanaparti
Copy link
Copy Markdown
Contributor Author

@blueorangutan package

@blueorangutan
Copy link
Copy Markdown

@sureshanaparti a [SL] Jenkins job has been kicked to build packages. It will be bundled with KVM, XenServer and VMware SystemVM templates. I'll keep you posted as I make progress.

@blueorangutan
Copy link
Copy Markdown

Packaging result [SF]: ✔️ el8 ✔️ el9 ✔️ el10 ✔️ debian ✔️ suse15. SL-JID 18009

@sureshanaparti sureshanaparti added this to the 4.22.2 milestone May 25, 2026
@DaanHoogland DaanHoogland requested a review from Copilot May 26, 2026 11:20
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot encountered an error and was unable to review this pull request. You can try again by re-requesting a review.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Don't allow vmsnapshot and volume snapshot operations on a vm which has encrypted volumes attached

3 participants