Cns Volume Manager APIs

Cns Volume Manager APIs

This is the interface for managing the lifecycle of volumes that are consumed by containers or pods, in case of Kubernetes.

This managed interface can be accessed through MOID of cns-volume-manager, through vSAN service in vCenter.

Lifecycle of a container volume includes creation, update, query, attach, detach and delete operations. This interface and its related classes are the entry point for Cloud Native Storage (abbreviated to CNS) service.

These requests could come from different container orchestrator clusters running on same vSphere as associated with this VolumeManager. VolumeManager is not aware of presence and topology of container orchestrator clusters, except for the weak association via CnsContainerCluster. This is a weak association because it's client's responsibility to provide unique identity for this container orchestrator cluster. VolumeManager will not impose any uniqueness verification on cluster identification.

Provisioning APIs of this interface return vim.Task which is vCenter Task object to track the progress of operation. In case of either partial or complete success, the state of the task would be set to success. In case of complete failure of the task when the individual specs couldn't be scheduled, the task status would be set to error. The corresponding fault, if any, will be set in the fault field. For a successfully scheduled task, result of this operation will be a list of CnsVolumeOperationResult instances. The client needs to go through the result and check the successful and failed instances.

The Task returned by provisioning APIs is a vim.Task object. Client needs to connect to vim endpoint on vCenter using the latest VSAN VMODL version (not latest VIM version) to monitor task status. After the task is complete, clients can refer to CnsVolumeOperationResult set as result field in task's TaskInfo field.

Please refer to the required privileges in the individual API documentation and ignore the Required Privileges section which is not used.

Operations
POST
Cns Volume Manager Cns Attach Volume
Attaches volumes(block volumes only) to specified VM instances, to make volumes ready for mount and consumption by respective containers.
POST
Cns Volume Manager Cns Configure Volume AC Ls
Modify the ACL configurations for existing volumes.
POST
Cns Volume Manager Cns Create Volume
Creates container volume with given specifications.
POST
Cns Volume Manager Cns Create Snapshots
Create snapshots of given volumes A volume with snapshot created on it, is considered in use and cannot be deleted.
POST
Cns Volume Manager Cns Delete Volume
Deletes given container volumes.
POST
Cns Volume Manager Cns Delete Snapshots
Delete snapshots with given volumeIds and snapshotIds.
POST
Cns Volume Manager Cns Detach Volume
Detaches volumes(block volumes only) and makes those volumes unavailable for consumption.
POST
Cns Volume Manager Cns Extend Volume
Extend the capacity for the container volumes.
POST
Cns Volume Manager Cns Query Volume
Returns container volumes matching criteria set in the filter.
POST
Cns Volume Manager Cns Query Async
Returns container volumes matching criteria set in the filter.
POST
Cns Volume Manager Cns Reconfig Volume Policy
Reconfigures the volume with the storage policy.
POST
Cns Volume Manager Cns Relocate Volume
Relocate container volume from the current source datastore to another destination datastore.
POST
Cns Volume Manager Cns Update Volume Metadata
Updates volume metadata, namely labels and container cluster information for the container volumes.