api, server, ui: allow host auto-select for migrateVirtualMachineWith…#6785
api, server, ui: allow host auto-select for migrateVirtualMachineWith…#6785shwstppr wants to merge 8 commits intoapache:mainfrom
Conversation
…Volume Fixes apache#6773 Signed-off-by: Abhishek Kumar <abhishek.mrt22@gmail.com>
|
Found UI changes, kicking a new UI QA build |
|
@acs-robot a Jenkins job has been kicked to build UI QA env. I'll keep you posted as I make progress. |
|
Found UI changes, kicking a new UI QA build |
|
@acs-robot a Jenkins job has been kicked to build UI QA env. I'll keep you posted as I make progress. |
|
UI build: ✔️ |
|
UI build: ✔️ |
|
SonarCloud Quality Gate failed. |
Codecov Report
@@ Coverage Diff @@
## main #6785 +/- ##
============================================
- Coverage 12.95% 12.95% -0.01%
Complexity 8986 8986
============================================
Files 2728 2728
Lines 256647 256656 +9
Branches 40024 40026 +2
============================================
Hits 33257 33257
- Misses 219210 219220 +10
+ Partials 4180 4179 -1
... and 1 file with indirect coverage changes 📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
|
@blueorangutan package |
|
@shwstppr a 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. |
|
Packaging result: ✔️ el7 ✔️ el8 ✔️ debian ✔️ suse15. SL-JID 4323 |
|
@blueorangutan test |
|
@DaanHoogland a Trillian-Jenkins test job (centos7 mgmt + kvm-centos7) has been kicked to run smoke tests |
|
@DaanHoogland please note I've not done any sort of testing for this yet |
I'll do some when I get around. Do you have any test advice on this? I couldn´t reproduce the issue on 4.17. |
|
@DaanHoogland To reproduce, I think one needs to just select Automatically assign in the migrate instance form for a vm that has volumes on local storage,
|
|
Trillian test result (tid-5059)
|
Did you test @weizhouapache ? I didn´t get to it yet. |
I have not tested it yet |
|
This pull request has merge conflicts. Dear author, please fix the conflicts and sync your branch with the base branch. |
...main/java/org/apache/cloudstack/api/command/admin/vm/MigrateVirtualMachineWithVolumeCmd.java
Outdated
Show resolved
Hide resolved
|
|
||
| private boolean isVmVolumesOnZoneWideStore(VMInstanceVO vm) { | ||
| final List<VolumeVO> volumes = _volsDao.findCreatedByInstance(vm.getId()); | ||
| private boolean isVmVolumesUsingLocalStorage(final List<VolumeVO> volumes) { |
There was a problem hiding this comment.
The code in this method looks exactly like the bit in isVmVolumesOnZoneWideStore
| if (destinationHost == null) { | ||
| Long poolId = null; | ||
| if (MapUtils.isNotEmpty(volToPoolObjectMap)) { | ||
| poolId = new ArrayList<>(volToPoolObjectMap.values()).get(0); | ||
| } | ||
| DeployDestination deployDestination = chooseVmMigrationDestination(vm, srcHost, poolId); | ||
| if (deployDestination == null) { | ||
| throw new CloudRuntimeException("Unable to find suitable destination to migrate VM " + vm.getInstanceName()); | ||
| } | ||
| destinationHost = deployDestination.getHost(); | ||
| } |
There was a problem hiding this comment.
can this be extracted?
|
@blueorangutan package |
|
@shwstppr a [SF] 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. |
|
Packaging result [SF]: ✖️ el7 ✔️ el8 ✔️ el9 ✖️ debian ✔️ suse15. SL-JID 6130 |
|
Packaging result [LL]: ✖️ el7 ✔️ el8 ✔️ el9 ✖️ debian ✔️ suse15. SL-JID 6054 |
|
Packaging result [LL]: ✖️ el7 ✔️ el8 ✔️ el9 ✖️ debian ✔️ suse15. SL-JID 6055 |
|
Packaging result [SF]: ✖️ el7 ✔️ el8 ✔️ el9 ✖️ debian ✔️ suse15. SL-JID 6136 |
|
@blueorangutan package |
|
@shwstppr a [SF] 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. |
|
Recreated here #7554 |









Description
Fixes #6773
Types of changes
Feature/Enhancement Scale or Bug Severity
Feature/Enhancement Scale
Bug Severity
Screenshots (if appropriate):
How Has This Been Tested?