Repository navigation
CSTACKEX-262: Support for Compute + Volume migration and Volume migration - #112
Merged
Merged
Conversation
sandeeplocharla
requested review from
piyush5netapp,
rajiv-jain-netapp and
suryag1201
as code owners
October 5, 2026 05:54
sandeeplocharla
force-pushed
the
feature/CSTACKEX-262
branch
from
October 5, 2026 06:26
15f8e29 to
ddcebda
Compare
sandeeplocharla
marked this pull request as draft
October 5, 2026 14:23
🔴 Test Coverage Grade:
|
| Metric | Value |
|---|---|
| Line coverage | 24.86% |
| Branch coverage | 18.99% |
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
sandeeplocharla
marked this pull request as ready for review
October 7, 2026 01:02
|
This pull request has merge conflicts. Dear author, please fix the conflicts and sync your branch with the base branch. |
sandeeplocharla
force-pushed
the
feature/CSTACKEX-262
branch
2 times, most recently
from
October 12, 2026 06:10
e5c27c5 to
9416f32
Compare
sandeeplocharla
force-pushed
the
feature/CSTACKEX-262
branch
from
October 12, 2026 07:35
9416f32 to
7bca4ca
Compare
|
This pull request has merge conflicts. Dear author, please fix the conflicts and sync your branch with the base branch. |
suryag1201
reviewed
Oct 15, 2026
sandeeplocharla
force-pushed
the
feature/CSTACKEX-262
branch
from
October 16, 2026 06:45
575b714 to
26664a6
Compare
🔴 Test Coverage Grade:
|
| Metric | Value |
|---|---|
| Line coverage | 25.98% |
| Branch coverage | 20.27% |
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
sandeeplocharla
force-pushed
the
feature/CSTACKEX-262
branch
from
October 26, 2026 13:33
26664a6 to
be02af2
Compare
|
This pull request has merge conflicts. Dear author, please fix the conflicts and sync your branch with the base branch. |
…ation # Conflicts: # plugins/storage/volume/ontap/src/main/java/org/apache/cloudstack/storage/driver/OntapPrimaryDatastoreDriver.java # plugins/storage/volume/ontap/src/main/java/org/apache/cloudstack/storage/service/UnifiedSANStrategy.java # plugins/storage/volume/ontap/src/test/java/org/apache/cloudstack/storage/driver/OntapPrimaryDatastoreDriverTest.java # plugins/storage/volume/ontap/src/test/java/org/apache/cloudstack/storage/service/UnifiedNASStrategyTest.java
…ject cross-protocol migration
# Conflicts: # plugins/storage/volume/ontap/src/main/java/org/apache/cloudstack/storage/service/UnifiedSANStrategy.java # plugins/storage/volume/ontap/src/test/java/org/apache/cloudstack/storage/service/UnifiedSANStrategyTest.java
- LunMap: drop property-level NON_DEFAULT JsonInclude on logicalUnitNumber - KVMStorageProcessor: prefer copy details over command options, narrow not-found handling to managed volumes - OntapDataMotionStrategy: add disconnectVolumeFromHost helper used by failed and post-migration cleanup - LibvirtMigrateCommandWrapper: remove the disconnect wrapper method and its test - Add unit tests for the copy-details precedence and the new cleanup path
…ration QoS Offline migration calls createAsync with a null callback and reads no result, so a failed create must throw instead of returning silently. The post-migration QoS reapply now retries twice more with a short wait, then logs and continues, because the VM has already moved and a failed patch must not expunge its disks.
The driver treated any unattached volume in Ready, Allocated or Creating state as an offline migration destination, so an ordinary volume about to be attached could get the migration-only host connect and NFS export policy update. OntapDataMotionStrategy now tags the offline destination with the ontap.migration.destination volume detail right after createAsync and clears it in the finally block. The driver connects the host for migration only when the volume is Migrating or carries that tag. The live path is unchanged because its destination is already Migrating.
…rate delayed LUN copy status - OntapDataMotionStrategy.copyAsync: add a catch-all that sets a proper error message, logs the exception details and rethrows, so the callback never reports success for an unexpected failure. - UnifiedSANStrategy.waitForLunCopy: tolerate a 404 or missing copy details from ONTAP for up to 60s before failing the copy.
sandeeplocharla
force-pushed
the
feature/CSTACKEX-262
branch
from
November 16, 2026 17:32
4497817 to
0889322
Compare
ONTAP storage plugin test coverage
|
sandeeplocharla
added a commit
that referenced
this pull request
Dec 1, 2026
…tion (#112) ### Description This PR... <!--- Describe your changes in DETAIL - And how has behaviour functionally changed. --> <!-- For new features, provide link to FS, dev ML discussion etc. --> <!-- In case of bug fix, the expected and actual behaviours, steps to reproduce. --> <!-- When "Fixes: #<id>" is specified, the issue/PR will automatically be closed when this PR gets merged --> <!-- For addressing multiple issues/PRs, use multiple "Fixes: #<id>" --> <!-- Fixes: # --> <!--- ******************************************************************************* --> <!--- NOTE: AUTOMATION USES THE DESCRIPTIONS TO SET LABELS AND PRODUCE DOCUMENTATION. --> <!--- PLEASE PUT AN 'X' in only **ONE** box --> <!--- ******************************************************************************* --> ### Types of changes - [ ] Breaking change (fix or feature that would cause existing functionality to change) - [X] 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 - [X] Test (unit or integration test code) ### Feature/Enhancement Scale or Bug Severity #### Feature/Enhancement Scale - [X] Major - [ ] Minor #### Bug Severity - [ ] BLOCKER - [ ] Critical - [ ] Major - [ ] Minor - [ ] Trivial | Use case | Suite | Tests | Result | | --- | --- | --- | --- | | Live VM migration with volumes | migration_live | 22 | Pass | | Stopped VM storage migration | migration_stopped | 15 | Pass | | Volume migration (detached or stopped-attached) | migration_volume | 23 | Pass | | iSCSI pool lifecycle | iscsi_pool_lifecycle | 8 | Pass | | iSCSI pool with volumes | iscsi_pool_volumes | 7 | Pass | | iSCSI zone-scoped pool | iscsi_zone_pool | 4 | Pass | | iSCSI volume lifecycle | iscsi_volume | 5 | Pass | | iSCSI VM volume attach | iscsi_instance | 8 | Pass | | NFS3 pool lifecycle | nfs3_pool_lifecycle | 8 | Pass | | NFS3 pool with volumes | nfs3_pool_volumes | 7 | Pass | | NFS3 zone-scoped pool | nfs3_zone_pool | 4 | Pass | | NFS3 volume lifecycle | nfs3_volume | 5 | Pass | | NFS3 VM volume attach | nfs3_instance | 8 | Pass | ### Live VM with volumes (`migrateVirtualMachineWithVolume`) | Test | What it covers | Status | | --- | --- | --- | | test_01_nfs3_default_primary_to_cluster | DefaultPrimary root and data volumes to NFS3 C1a | Pass | | test_02_nfs3_cluster_to_cluster | NFS3 C1a to C1b | Pass | | test_03_nfs3_cluster_to_zone | NFS3 C1b to zone-wide Z1 | Pass | | test_04_nfs3_zone_to_zone | NFS3 Z1 to Z2 | Pass | | test_05_nfs3_zone_to_cluster | NFS3 Z2 back to C1a | Pass | | test_06_iscsi_default_primary_to_cluster | DefaultPrimary root and data volumes to iSCSI C1a | Pass | | test_07_iscsi_cluster_to_cluster | iSCSI C1a to C1b | Pass | | test_08_iscsi_cluster_to_zone | iSCSI C1b to Z1 | Pass | | test_09_iscsi_zone_to_zone | iSCSI Z1 to Z2 | Pass | | test_10_iscsi_zone_to_cluster | iSCSI Z2 back to C1a | Pass | | test_11_reject_nfs3_to_iscsi | Live NFS3-to-iSCSI mapping is rejected | Pass | | test_12_reject_iscsi_to_nfs3 | Live iSCSI-to-NFS3 mapping is rejected | Pass | | test_13_reject_live_volume_only | `migrateVolume` with livemigrate on a running volume is rejected | Pass | | test_14_nfs3_cluster_to_cluster | After host split, NFS3 C1a to C2 | Pass | | test_15_nfs3_cluster_to_zone | NFS3 C1a to Z1 onto a C2 host | Pass | | test_16_nfs3_zone_to_cluster | NFS3 Z1 to C2 | Pass | | test_17_nfs3_zone_to_zone | NFS3 Z1 to Z2 onto a C2 host | Pass | | test_18_iscsi_cluster_to_cluster | iSCSI C1a to C2 onto a C2 host | Pass | | test_19_iscsi_cluster_to_zone | iSCSI C1a to Z1 onto a C2 host | Pass | | test_20_iscsi_zone_to_cluster | iSCSI Z1 to C2 | Pass | | test_21_iscsi_zone_to_zone | iSCSI Z1 to Z2 onto a C2 host | Pass | | test_22_reject_pool_not_reachable_from_destination_host | Cluster-1 pool mapped to a cluster-2 host is rejected | Pass | ### Stopped VM storage migration (`migrateVirtualMachineWithVolume`, no destination host) | Test | What it covers | Status | | --- | --- | --- | | test_01_nfs3_default_primary_to_cluster | DefaultPrimary to NFS3 C1a | Pass | | test_02_nfs3_cluster_to_cluster_same_cluster | NFS3 between cluster pools in the same cluster | Pass | | test_03_nfs3_cluster_to_cluster_across_clusters | NFS3 to a pool in the second cluster | Pass | | test_04_nfs3_cluster_to_zone | NFS3 cluster pool to zone-wide | Pass | | test_05_nfs3_zone_to_zone | NFS3 between two zone-wide pools | Pass | | test_06_nfs3_zone_to_cluster | NFS3 zone-wide back to C1a | Pass | | test_07_iscsi_default_primary_to_cluster | DefaultPrimary to iSCSI C1a | Pass | | test_08_iscsi_cluster_to_cluster_same_cluster | iSCSI between cluster pools in the same cluster | Pass | | test_09_iscsi_cluster_to_cluster_across_clusters | iSCSI to a pool in the second cluster | Pass | | test_10_iscsi_cluster_to_zone | iSCSI cluster pool to zone-wide | Pass | | test_11_iscsi_zone_to_zone | iSCSI between two zone-wide pools | Pass | | test_12_iscsi_zone_to_cluster | iSCSI zone-wide back to C1a | Pass | | test_13_reject_nfs3_to_iscsi | Stopped-VM NFS3-to-iSCSI is rejected | Pass | | test_14_reject_iscsi_to_nfs3 | Stopped-VM iSCSI-to-NFS3 is rejected | Pass | | test_15_reject_running_vm | Stopped-VM API form is rejected once the VM is running | Pass | ### Volume migration (`migrateVolume`) | Test | What it covers | Status | | --- | --- | --- | | test_01_nfs3_detached_default_primary_to_cluster | Detached NFS3, DefaultPrimary to C1a | Pass | | test_02_nfs3_detached_cluster_to_cluster_same_cluster | Detached NFS3, C1a to C1b | Pass | | test_03_nfs3_detached_cluster_to_cluster_across_clusters | Detached NFS3, C1b to C2 | Pass | | test_04_nfs3_detached_cluster_to_zone | Detached NFS3, C2 to Z1 | Pass | | test_05_nfs3_detached_zone_to_zone | Detached NFS3, Z1 to Z2 | Pass | | test_06_nfs3_detached_zone_to_cluster | Detached NFS3, Z2 back to C1a | Pass | | test_07_iscsi_detached_default_primary_to_cluster | Detached iSCSI, DefaultPrimary to C1a | Pass | | test_08_iscsi_detached_cluster_to_cluster_same_cluster | Detached iSCSI, C1a to C1b | Pass | | test_09_iscsi_detached_cluster_to_cluster_across_clusters | Detached iSCSI, C1b to C2 | Pass | | test_10_iscsi_detached_cluster_to_zone | Detached iSCSI, C2 to Z1 | Pass | | test_11_iscsi_detached_zone_to_zone | Detached iSCSI, Z1 to Z2 | Pass | | test_12_iscsi_detached_zone_to_cluster | Detached iSCSI, Z2 back to C1a | Pass | | test_13_nfs3_attached_stopped_vm_cluster_to_zone | Stopped-attached NFS3 data, C1a to Z1; root stays | Pass | | test_14_iscsi_attached_stopped_vm_cluster_to_zone | Stopped-attached iSCSI data, C1a to Z1; root stays | Pass | | test_15_nfs3_attached_stopped_vm_default_to_ontap | Stopped-attached non-ONTAP data to ONTAP NFS3 | Pass | | test_16_iscsi_attached_stopped_vm_default_to_ontap | Stopped-attached non-ONTAP data to ONTAP iSCSI | Pass | | test_17_reject_detached_nfs3_to_iscsi | Detached NFS3-to-iSCSI is rejected | Pass | | test_18_reject_detached_iscsi_to_nfs3 | Detached iSCSI-to-NFS3 is rejected | Pass | | test_19_reject_stopped_attached_nfs3_to_iscsi | Stopped-attached NFS3-to-iSCSI is rejected | Pass | | test_20_reject_stopped_attached_iscsi_to_nfs3 | Stopped-attached iSCSI-to-NFS3 is rejected | Pass | | test_21_reject_attached_running_vm_without_livemigrate | Running-attached NFS3 without livemigrate is rejected | Pass | | test_22_reject_attached_running_vm_with_livemigrate | Live volume-only migration is rejected | Pass | | test_23_reject_same_pool | Migration to the volume's current pool is rejected | Pass |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
This PR...
Types of changes
Feature/Enhancement Scale or Bug Severity
Feature/Enhancement Scale
Bug Severity
Live VM with volumes (
migrateVirtualMachineWithVolume)migrateVolumewith livemigrate on a running volume is rejectedStopped VM storage migration (
migrateVirtualMachineWithVolume, no destination host)Volume migration (
migrateVolume)