| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
… in deploySharedFSVM()
There was a problem hiding this comment.
This PR addresses an intermittent NullPointerException during SharedFS VM deployment by ensuring unsupported hypervisors (or hypervisors without a downloaded SystemVM template) don’t cause template dereferences, and by tightening the hypervisor list used for SystemVM-based deployments.
Changes:
Copilot reviewed 5 out of 5 changed files in this pull request and generated 2 comments.
Show a summary per file| File | Description |
|---|---|
| server/src/test/java/com/cloud/resource/MockResourceManagerImpl.java | Updates mock method signature to match the renamed boolean parameter. |
| server/src/main/java/com/cloud/resource/ResourceManagerImpl.java | Renames the boolean parameter and keeps filtering logic for SystemVM-oriented hypervisor selection. |
| plugins/storage/sharedfs/storagevm/src/test/java/org/apache/cloudstack/storage/sharedfs/lifecycle/StorageVmSharedFSLifeCycleTest.java | Updates stubs to call getSupportedHypervisorTypes(..., true, ...) for SharedFS deployment tests. |
| plugins/storage/sharedfs/storagevm/src/main/java/org/apache/cloudstack/storage/sharedfs/lifecycle/StorageVmSharedFSLifeCycle.java | Uses SystemVM-filtered hypervisors and prevents NPE by continuing when templates are missing. |
| api/src/main/java/com/cloud/resource/ResourceService.java | Renames the boolean parameter in the API interface to reflect SystemVM intent. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Sorry, something went wrong.
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Codecov Report❌ Patch coverage is 50.00000% with 2 lines in your changes missing coverage. Please review.
@@ Coverage Diff @@
## 4.22 #13930 +/- ##
============================================
+ Coverage 17.86% 17.92% +0.06%
- Complexity 16037 16113 +76
============================================
Files 5928 5928
Lines 534479 534964 +485
Branches 65410 65463 +53
============================================
+ Hits 95468 95876 +408
- Misses 428173 428180 +7
- Partials 10838 10908 +70
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness.
|
Sorry, something went wrong.
|
@abh1sar 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. |
Sorry, something went wrong.
|
Packaging result [SF]: ✔️ el8 ✔️ el9 ✔️ el10 ✔️ debian ✔️ suse15. SL-JID 18928 |
Sorry, something went wrong.
|
@GaOrtiga , did you happen to test? |
Sorry, something went wrong.
|
No @DaanHoogland , only code review. |
Sorry, something went wrong.
|
This pull request has merge conflicts. Dear author, please fix the conflicts and sync your branch with the base branch. |
Sorry, something went wrong.
|
Although the main issue was already fixed by #13830, this PR offers a more complete fix. |
Sorry, something went wrong.
|
@abh1sar 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. |
Sorry, something went wrong.
|
Packaging result [SF]: ✖️ el8 ✖️ el9 ✖️ debian ✖️ suse15. SL-JID 19181 |
Sorry, something went wrong.
|
@abh1sar 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. |
Sorry, something went wrong.
|
Packaging result [SF]: ✔️ el8 ✔️ el9 ✔️ el10 ✔️ debian ✔️ suse15. SL-JID 19197 |
Sorry, something went wrong.
There was a problem hiding this comment.
LGTM
Tested on a zone with an External (Proxmox) cluster next to KVM and VMware, which is the setup from #13837. SystemVM templates were present for KVM and VMware only and none for External, so the conditions for the NPE were in place.
Created Shared FileSystems repeatedly, 12 in total, since the original failure was intermittent and depended on where External landed in the shuffled list. No NPE on any of them and nothing in the management server log. Every deploy that had capacity landed on KVM and never on External.
The only failures I saw were InsufficientServerCapacityException, from the VMware hosts in this zone being down and from my own testing filling the environment up. Neither is related to this change.
Great work @abh1sar !
Sorry, something went wrong.
* origin/main: (156 commits) Upgrade Netris SDK version to 1.1.0 since 24.0 (apache#14365) feature: instance boot group and readiness rules (apache#13907) dont show unathorized notification for prelogin (apache#14054) .github: Upgrade docker/login-action to fix ASF Allowlist failure (apache#14276) virtual router: Add route-maps to BGP peers for Routed Mode (apache#9964) Add pre-commit hook to validate dependabot.yml (apache#14107) Add the ASF Allowlist check workflow (apache#14113) Revert "VMware to KVM: cold (VDDK) and warm (CBT) migration into Ceph/RBD and Linstor, plus importVm adoption of existing RBD root volumes and Linstor root/data volumes (apache#13656)" VMware to KVM: cold (VDDK) and warm (CBT) migration into Ceph/RBD and Linstor, plus importVm adoption of existing RBD root volumes and Linstor root/data volumes (apache#13656) engine-schema: upgrade path for 24.0.0 (apache#14033) xenserver/xcpng: do not bypass secondary storage when copy volumes between pools (apache#13750) backport: Incremental NAS backup support for KVM (apache#13074) (apache#13877) storage: KVM - enable RBD/Ceph volume encryption support (apache#13556) backup: remove the powered-off precondition for all backup providers (apache#14094) Nas backup: Fix mount/unmount error handling and timeout in LibvirtRestoreBackupCommandWrapper (apache#14006) kvm: apply rbd_default_data_pool when creating volumes from templates on RBD (apache#13361) server: copy template details to vm instance details when import VM (apache#12793) marvin: use pycryptodome instead of PyCrypt (apache#13594) Packaging: accept normalized Marvin archive names (apache#13793) SharedFS: fix NPE when accessing systemvm templates for unsupported hypervisors (apache#13930) ...
| Back | FazBrowse Home | New Git URL |
Description
This PR fixes #13837
Types of changes
Feature/Enhancement Scale or Bug Severity
Feature/Enhancement Scale
Bug Severity
Screenshots (if appropriate):
How Has This Been Tested?
How did you try to break this feature and the system with this change?