Introduction of Netapp Ontap iSCSI pool type - #14192
piyush5netapp wants to merge 2 commits into
Conversation
|
@winterhazel @weizhouapache I have raised this PR for the introduction of new iscsi pool type for Netapp ONTAP. I remember you guys were also of the same opinion for a new pool type for Netapp ONTAP as part of some previous PR.. Please have a look at this PR and share your feedback. |
There was a problem hiding this comment.
Copilot review overview
🟡 Changes recommended
Existing pools can break after upgrade, unsupported format validation can orphan LUNs, and template creation still rejects RAW ONTAP iSCSI volumes.
Get a fresh assessment by requesting another Copilot review.
Review effort: Lite
Findings: 2
Open (3)
What changed in this PR
Adds OntapiSCSI as a first-class ONTAP iSCSI storage-pool type across management, KVM agent, and data-motion paths.
Changes:
- Adds the new pool enum and lifecycle mapping.
- Adds KVM adaptor and RAW image-format handling.
- Extends validation and tests for ONTAP iSCSI behavior.
| File | Description |
|---|---|
api/src/main/java/com/cloud/storage/Storage.java |
Defines OntapiSCSI. |
server/src/main/java/com/cloud/api/ApiDBUtils.java |
Recognizes RAW ONTAP images. |
plugins/storage/volume/ontap/src/main/java/.../OntapPrimaryDatastoreLifecycle.java |
Maps iSCSI pools to the new type. |
plugins/storage/volume/ontap/src/main/java/.../OntapPrimaryDatastoreDriver.java |
Validates protocols and assigns formats. |
plugins/hypervisors/kvm/src/main/java/.../OntapIscsiStorageAdaptor.java |
Registers the KVM adaptor. |
plugins/hypervisors/kvm/src/main/java/.../KVMStorageProcessor.java |
Handles RAW ONTAP pools. |
engine/storage/datamotion/src/main/java/.../StorageSystemDataMotionStrategy.java |
Allows RAW ONTAP migration formats. |
api/src/test/java/com/cloud/storage/StorageTest.java |
Tests pool capabilities. |
plugins/storage/volume/ontap/src/test/java/.../OntapPrimaryDatastoreLifecycleTest.java |
Tests pool initialization. |
plugins/storage/volume/ontap/src/test/java/.../OntapPrimaryDatastoreDriverTest.java |
Tests format and validation behavior. |
plugins/hypervisors/kvm/src/test/java/.../OntapIscsiStorageAdaptorTest.java |
Tests adaptor discovery and RAW behavior. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
|
|
||
| volumeVO.setPoolType(storagePool.getPoolType()); | ||
| volumeVO.setPoolId(storagePool.getId()); | ||
| volumeVO.setFormat(getImageFormat(storagePool)); |
| break; | ||
| case ISCSI: | ||
| parameters.setType(Storage.StoragePoolType.Iscsi); | ||
| parameters.setType(Storage.StoragePoolType.OntapiSCSI); |
| !(imageFormat == ImageFormat.RAW && (StoragePoolType.PowerFlex == poolType || | ||
| StoragePoolType.FiberChannel == poolType))) { | ||
| throw new CloudRuntimeException(String.format("Only the following image types are currently supported: %s, %s, %s, %s (for PowerFlex and FiberChannel)", | ||
| StoragePoolType.FiberChannel == poolType || StoragePoolType.OntapiSCSI == poolType))) { |
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #14192 +/- ##
============================================
+ Coverage 19.91% 19.92% +0.01%
- Complexity 20175 20192 +17
============================================
Files 6372 6373 +1
Lines 577139 577168 +29
Branches 70682 70689 +7
============================================
+ Hits 114913 114982 +69
+ Misses 449664 449618 -46
- Partials 12562 12568 +6
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:
|


Description
This PR introduces the new pool type "OntapiSCSI" for Netapp Ontap. We have also introduced the management as well as agent side of code to support this new pool type.
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?