nutanix_volumes 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +7 -0
- data/CHANGELOG.md +11 -0
- data/Gemfile +9 -0
- data/README.md +290 -0
- data/Rakefile +10 -0
- data/docs/AssociateCategory202Response.md +20 -0
- data/docs/AssociateCategory4XXResponse.md +20 -0
- data/docs/AttachIscsiClient202Response.md +20 -0
- data/docs/AttachIscsiClient4XXResponse.md +20 -0
- data/docs/AttachVm202Response.md +20 -0
- data/docs/AttachVm4XXResponse.md +20 -0
- data/docs/CommonV10ConfigEntityReference.md +24 -0
- data/docs/CommonV10ConfigEntityType.md +15 -0
- data/docs/CommonV10ConfigFQDN.md +18 -0
- data/docs/CommonV10ConfigFlag.md +20 -0
- data/docs/CommonV10ConfigIPAddressOrFQDN.md +22 -0
- data/docs/CommonV10ConfigIPv4Address.md +20 -0
- data/docs/CommonV10ConfigIPv6Address.md +20 -0
- data/docs/CommonV10ConfigKVPair.md +20 -0
- data/docs/CommonV10ConfigKVPairValue.md +59 -0
- data/docs/CommonV10ConfigMapOfStringWrapper.md +18 -0
- data/docs/CommonV10ConfigMessage.md +24 -0
- data/docs/CommonV10ConfigMessageSeverity.md +15 -0
- data/docs/CommonV10ConfigMetadata.md +26 -0
- data/docs/CommonV10ConfigTenantAwareModel.md +18 -0
- data/docs/CommonV10ResponseApiLink.md +20 -0
- data/docs/CommonV10ResponseApiResponseMetadata.md +26 -0
- data/docs/CommonV10ResponseExternalizableAbstractModel.md +22 -0
- data/docs/CommonV10StatsDownSamplingOperator.md +15 -0
- data/docs/CreateVolumeDisk202Response.md +20 -0
- data/docs/CreateVolumeDisk4XXResponse.md +20 -0
- data/docs/CreateVolumeGroup202Response.md +20 -0
- data/docs/CreateVolumeGroup4XXResponse.md +20 -0
- data/docs/DeleteVolumeDiskById202Response.md +20 -0
- data/docs/DeleteVolumeDiskById4XXResponse.md +20 -0
- data/docs/DeleteVolumeGroupById202Response.md +20 -0
- data/docs/DeleteVolumeGroupById4XXResponse.md +20 -0
- data/docs/DetachIscsiClient202Response.md +20 -0
- data/docs/DetachIscsiClient4XXResponse.md +20 -0
- data/docs/DetachVm202Response.md +20 -0
- data/docs/DetachVm4XXResponse.md +20 -0
- data/docs/DisassociateCategory202Response.md +20 -0
- data/docs/DisassociateCategory4XXResponse.md +20 -0
- data/docs/GetIscsiClientById200Response.md +20 -0
- data/docs/GetIscsiClientById4XXResponse.md +20 -0
- data/docs/GetVolumeDiskById200Response.md +20 -0
- data/docs/GetVolumeDiskById4XXResponse.md +20 -0
- data/docs/GetVolumeDiskStats200Response.md +20 -0
- data/docs/GetVolumeDiskStats4XXResponse.md +20 -0
- data/docs/GetVolumeGroupById200Response.md +20 -0
- data/docs/GetVolumeGroupById4XXResponse.md +20 -0
- data/docs/GetVolumeGroupMetadataById200Response.md +20 -0
- data/docs/GetVolumeGroupMetadataById4XXResponse.md +20 -0
- data/docs/GetVolumeGroupStats200Response.md +20 -0
- data/docs/GetVolumeGroupStats4XXResponse.md +20 -0
- data/docs/IscsiClientsApi.md +253 -0
- data/docs/ListCategoryAssociationsByVolumeGroupId200Response.md +20 -0
- data/docs/ListCategoryAssociationsByVolumeGroupId4XXResponse.md +20 -0
- data/docs/ListExternalIscsiAttachmentsByVolumeGroupId200Response.md +20 -0
- data/docs/ListExternalIscsiAttachmentsByVolumeGroupId4XXResponse.md +20 -0
- data/docs/ListIscsiClients200Response.md +20 -0
- data/docs/ListIscsiClients4XXResponse.md +20 -0
- data/docs/ListVmAttachmentsByVolumeGroupId200Response.md +20 -0
- data/docs/ListVmAttachmentsByVolumeGroupId4XXResponse.md +20 -0
- data/docs/ListVolumeDisksByVolumeGroupId200Response.md +20 -0
- data/docs/ListVolumeDisksByVolumeGroupId4XXResponse.md +20 -0
- data/docs/ListVolumeGroups200Response.md +20 -0
- data/docs/ListVolumeGroups4XXResponse.md +20 -0
- data/docs/PrismV40ConfigTaskReference.md +18 -0
- data/docs/RevertVolumeGroup202Response.md +20 -0
- data/docs/RevertVolumeGroup4XXResponse.md +20 -0
- data/docs/UpdateIscsiClientById202Response.md +20 -0
- data/docs/UpdateIscsiClientById4XXResponse.md +20 -0
- data/docs/UpdateVolumeDiskById202Response.md +20 -0
- data/docs/UpdateVolumeDiskById4XXResponse.md +20 -0
- data/docs/UpdateVolumeGroupById202Response.md +20 -0
- data/docs/UpdateVolumeGroupById4XXResponse.md +20 -0
- data/docs/VolumeGroupsApi.md +1887 -0
- data/docs/VolumesV40ConfigAssociateCategoryApiResponse.md +20 -0
- data/docs/VolumesV40ConfigAttachIscsiClientApiResponse.md +20 -0
- data/docs/VolumesV40ConfigAttachNvmfClientApiResponse.md +20 -0
- data/docs/VolumesV40ConfigAttachVmApiResponse.md +20 -0
- data/docs/VolumesV40ConfigAttachmentType.md +15 -0
- data/docs/VolumesV40ConfigAuthenticationType.md +15 -0
- data/docs/VolumesV40ConfigCategoryDetails.md +24 -0
- data/docs/VolumesV40ConfigCategoryEntityReferences.md +18 -0
- data/docs/VolumesV40ConfigCluster.md +20 -0
- data/docs/VolumesV40ConfigCreateVolumeDiskApiResponse.md +20 -0
- data/docs/VolumesV40ConfigCreateVolumeGroupApiResponse.md +20 -0
- data/docs/VolumesV40ConfigDeleteVolumeDiskApiResponse.md +20 -0
- data/docs/VolumesV40ConfigDeleteVolumeGroupApiResponse.md +20 -0
- data/docs/VolumesV40ConfigDetachIscsiClientApiResponse.md +20 -0
- data/docs/VolumesV40ConfigDetachNvmfClientApiResponse.md +20 -0
- data/docs/VolumesV40ConfigDetachVmApiResponse.md +20 -0
- data/docs/VolumesV40ConfigDisassociateCategoryApiResponse.md +20 -0
- data/docs/VolumesV40ConfigDiskStorageFeatures.md +18 -0
- data/docs/VolumesV40ConfigFlashMode.md +18 -0
- data/docs/VolumesV40ConfigGetIscsiClientApiResponse.md +20 -0
- data/docs/VolumesV40ConfigGetIscsiClientApiResponseData.md +49 -0
- data/docs/VolumesV40ConfigGetVolumeDiskApiResponse.md +20 -0
- data/docs/VolumesV40ConfigGetVolumeDiskApiResponseData.md +49 -0
- data/docs/VolumesV40ConfigGetVolumeGroupApiResponse.md +20 -0
- data/docs/VolumesV40ConfigGetVolumeGroupApiResponseData.md +49 -0
- data/docs/VolumesV40ConfigGetVolumeGroupMetadataApiResponse.md +20 -0
- data/docs/VolumesV40ConfigGetVolumeGroupMetadataApiResponseData.md +49 -0
- data/docs/VolumesV40ConfigIscsiClient.md +38 -0
- data/docs/VolumesV40ConfigIscsiClientAttachment.md +20 -0
- data/docs/VolumesV40ConfigIscsiFeatures.md +20 -0
- data/docs/VolumesV40ConfigListCategoryAssociationsApiResponse.md +20 -0
- data/docs/VolumesV40ConfigListCategoryAssociationsApiResponseData.md +49 -0
- data/docs/VolumesV40ConfigListExternalIscsiAttachmentsApiResponse.md +20 -0
- data/docs/VolumesV40ConfigListExternalIscsiAttachmentsApiResponseData.md +49 -0
- data/docs/VolumesV40ConfigListIscsiClientsApiResponse.md +20 -0
- data/docs/VolumesV40ConfigListIscsiClientsApiResponseData.md +49 -0
- data/docs/VolumesV40ConfigListVmAttachmentsApiResponse.md +20 -0
- data/docs/VolumesV40ConfigListVmAttachmentsApiResponseData.md +49 -0
- data/docs/VolumesV40ConfigListVolumeDisksApiResponse.md +20 -0
- data/docs/VolumesV40ConfigListVolumeDisksApiResponseData.md +49 -0
- data/docs/VolumesV40ConfigListVolumeGroupsApiResponse.md +20 -0
- data/docs/VolumesV40ConfigListVolumeGroupsApiResponseData.md +49 -0
- data/docs/VolumesV40ConfigMigrateVolumeGroupApiResponse.md +20 -0
- data/docs/VolumesV40ConfigNvmfClient.md +28 -0
- data/docs/VolumesV40ConfigNvmfClientAttachment.md +24 -0
- data/docs/VolumesV40ConfigPauseVolumeGroupSynchronousReplicationApiResponse.md +20 -0
- data/docs/VolumesV40ConfigProtocol.md +15 -0
- data/docs/VolumesV40ConfigResumeVolumeGroupSynchronousReplicationApiResponse.md +20 -0
- data/docs/VolumesV40ConfigResumeVolumeGroupSynchronousReplicationApiResponseData.md +47 -0
- data/docs/VolumesV40ConfigRevertSpec.md +18 -0
- data/docs/VolumesV40ConfigRevertVolumeGroupApiResponse.md +20 -0
- data/docs/VolumesV40ConfigSharingStatus.md +15 -0
- data/docs/VolumesV40ConfigStorageFeatures.md +18 -0
- data/docs/VolumesV40ConfigTargetParam.md +20 -0
- data/docs/VolumesV40ConfigUpdateIscsiClientApiResponse.md +20 -0
- data/docs/VolumesV40ConfigUpdateIscsiClientApiResponseData.md +49 -0
- data/docs/VolumesV40ConfigUpdateIscsiClientByIdApiResponse.md +20 -0
- data/docs/VolumesV40ConfigUpdateVolumeDiskApiResponse.md +20 -0
- data/docs/VolumesV40ConfigUpdateVolumeDiskByIdApiResponse.md +20 -0
- data/docs/VolumesV40ConfigUpdateVolumeGroupApiResponse.md +20 -0
- data/docs/VolumesV40ConfigUpdateVolumeGroupByIdApiResponse.md +20 -0
- data/docs/VolumesV40ConfigUpdateVolumeGroupMetadataApiResponse.md +20 -0
- data/docs/VolumesV40ConfigUpdateVolumeGroupMetadataInfoApiResponse.md +20 -0
- data/docs/VolumesV40ConfigUsageType.md +15 -0
- data/docs/VolumesV40ConfigVmAttachment.md +20 -0
- data/docs/VolumesV40ConfigVolumeDisk.md +34 -0
- data/docs/VolumesV40ConfigVolumeGroup.md +54 -0
- data/docs/VolumesV40ConfigVolumeGroupAttachmentSite.md +15 -0
- data/docs/VolumesV40ConfigVolumeGroupMetadata.md +20 -0
- data/docs/VolumesV40ErrorAppMessage.md +28 -0
- data/docs/VolumesV40ErrorErrorResponse.md +18 -0
- data/docs/VolumesV40ErrorErrorResponseError.md +49 -0
- data/docs/VolumesV40ErrorMessageSeverity.md +15 -0
- data/docs/VolumesV40ErrorSchemaValidationError.md +26 -0
- data/docs/VolumesV40ErrorSchemaValidationErrorMessage.md +22 -0
- data/docs/VolumesV40StatsGetVolumeDiskStatsApiResponse.md +20 -0
- data/docs/VolumesV40StatsGetVolumeDiskStatsApiResponseData.md +49 -0
- data/docs/VolumesV40StatsGetVolumeGroupStatsApiResponse.md +20 -0
- data/docs/VolumesV40StatsGetVolumeGroupStatsApiResponseData.md +49 -0
- data/docs/VolumesV40StatsTimeValuePair.md +20 -0
- data/docs/VolumesV40StatsVolumeDiskStats.md +44 -0
- data/docs/VolumesV40StatsVolumeGroupStats.md +44 -0
- data/git_push.sh +57 -0
- data/lib/nutanix_volumes/api/iscsi_clients_api.rb +270 -0
- data/lib/nutanix_volumes/api/volume_groups_api.rb +2003 -0
- data/lib/nutanix_volumes/api_client.rb +394 -0
- data/lib/nutanix_volumes/api_error.rb +58 -0
- data/lib/nutanix_volumes/configuration.rb +315 -0
- data/lib/nutanix_volumes/models/associate_category202_response.rb +224 -0
- data/lib/nutanix_volumes/models/associate_category4_xx_response.rb +224 -0
- data/lib/nutanix_volumes/models/attach_iscsi_client202_response.rb +224 -0
- data/lib/nutanix_volumes/models/attach_iscsi_client4_xx_response.rb +224 -0
- data/lib/nutanix_volumes/models/attach_vm202_response.rb +224 -0
- data/lib/nutanix_volumes/models/attach_vm4_xx_response.rb +224 -0
- data/lib/nutanix_volumes/models/common_v10_config_entity_reference.rb +336 -0
- data/lib/nutanix_volumes/models/common_v10_config_entity_type.rb +68 -0
- data/lib/nutanix_volumes/models/common_v10_config_flag.rb +256 -0
- data/lib/nutanix_volumes/models/common_v10_config_fqdn.rb +237 -0
- data/lib/nutanix_volumes/models/common_v10_config_ip_address_or_fqdn.rb +233 -0
- data/lib/nutanix_volumes/models/common_v10_config_ipv4_address.rb +284 -0
- data/lib/nutanix_volumes/models/common_v10_config_ipv6_address.rb +284 -0
- data/lib/nutanix_volumes/models/common_v10_config_kv_pair.rb +253 -0
- data/lib/nutanix_volumes/models/common_v10_config_kv_pair_value.rb +111 -0
- data/lib/nutanix_volumes/models/common_v10_config_map_of_string_wrapper.rb +218 -0
- data/lib/nutanix_volumes/models/common_v10_config_message.rb +268 -0
- data/lib/nutanix_volumes/models/common_v10_config_message_severity.rb +43 -0
- data/lib/nutanix_volumes/models/common_v10_config_metadata.rb +366 -0
- data/lib/nutanix_volumes/models/common_v10_config_tenant_aware_model.rb +237 -0
- data/lib/nutanix_volumes/models/common_v10_response_api_link.rb +226 -0
- data/lib/nutanix_volumes/models/common_v10_response_api_response_metadata.rb +376 -0
- data/lib/nutanix_volumes/models/common_v10_response_externalizable_abstract_model.rb +312 -0
- data/lib/nutanix_volumes/models/common_v10_stats_down_sampling_operator.rb +46 -0
- data/lib/nutanix_volumes/models/create_volume_disk202_response.rb +224 -0
- data/lib/nutanix_volumes/models/create_volume_disk4_xx_response.rb +224 -0
- data/lib/nutanix_volumes/models/create_volume_group202_response.rb +224 -0
- data/lib/nutanix_volumes/models/create_volume_group4_xx_response.rb +224 -0
- data/lib/nutanix_volumes/models/delete_volume_disk_by_id202_response.rb +224 -0
- data/lib/nutanix_volumes/models/delete_volume_disk_by_id4_xx_response.rb +224 -0
- data/lib/nutanix_volumes/models/delete_volume_group_by_id202_response.rb +224 -0
- data/lib/nutanix_volumes/models/delete_volume_group_by_id4_xx_response.rb +224 -0
- data/lib/nutanix_volumes/models/detach_iscsi_client202_response.rb +224 -0
- data/lib/nutanix_volumes/models/detach_iscsi_client4_xx_response.rb +224 -0
- data/lib/nutanix_volumes/models/detach_vm202_response.rb +224 -0
- data/lib/nutanix_volumes/models/detach_vm4_xx_response.rb +224 -0
- data/lib/nutanix_volumes/models/disassociate_category202_response.rb +224 -0
- data/lib/nutanix_volumes/models/disassociate_category4_xx_response.rb +224 -0
- data/lib/nutanix_volumes/models/get_iscsi_client_by_id200_response.rb +224 -0
- data/lib/nutanix_volumes/models/get_iscsi_client_by_id4_xx_response.rb +224 -0
- data/lib/nutanix_volumes/models/get_volume_disk_by_id200_response.rb +224 -0
- data/lib/nutanix_volumes/models/get_volume_disk_by_id4_xx_response.rb +224 -0
- data/lib/nutanix_volumes/models/get_volume_disk_stats200_response.rb +224 -0
- data/lib/nutanix_volumes/models/get_volume_disk_stats4_xx_response.rb +224 -0
- data/lib/nutanix_volumes/models/get_volume_group_by_id200_response.rb +224 -0
- data/lib/nutanix_volumes/models/get_volume_group_by_id4_xx_response.rb +224 -0
- data/lib/nutanix_volumes/models/get_volume_group_metadata_by_id200_response.rb +224 -0
- data/lib/nutanix_volumes/models/get_volume_group_metadata_by_id4_xx_response.rb +224 -0
- data/lib/nutanix_volumes/models/get_volume_group_stats200_response.rb +224 -0
- data/lib/nutanix_volumes/models/get_volume_group_stats4_xx_response.rb +224 -0
- data/lib/nutanix_volumes/models/list_category_associations_by_volume_group_id200_response.rb +226 -0
- data/lib/nutanix_volumes/models/list_category_associations_by_volume_group_id4_xx_response.rb +224 -0
- data/lib/nutanix_volumes/models/list_external_iscsi_attachments_by_volume_group_id200_response.rb +226 -0
- data/lib/nutanix_volumes/models/list_external_iscsi_attachments_by_volume_group_id4_xx_response.rb +224 -0
- data/lib/nutanix_volumes/models/list_iscsi_clients200_response.rb +226 -0
- data/lib/nutanix_volumes/models/list_iscsi_clients4_xx_response.rb +224 -0
- data/lib/nutanix_volumes/models/list_vm_attachments_by_volume_group_id200_response.rb +226 -0
- data/lib/nutanix_volumes/models/list_vm_attachments_by_volume_group_id4_xx_response.rb +224 -0
- data/lib/nutanix_volumes/models/list_volume_disks_by_volume_group_id200_response.rb +226 -0
- data/lib/nutanix_volumes/models/list_volume_disks_by_volume_group_id4_xx_response.rb +224 -0
- data/lib/nutanix_volumes/models/list_volume_groups200_response.rb +226 -0
- data/lib/nutanix_volumes/models/list_volume_groups4_xx_response.rb +224 -0
- data/lib/nutanix_volumes/models/prism_v40_config_task_reference.rb +237 -0
- data/lib/nutanix_volumes/models/revert_volume_group202_response.rb +224 -0
- data/lib/nutanix_volumes/models/revert_volume_group4_xx_response.rb +224 -0
- data/lib/nutanix_volumes/models/update_iscsi_client_by_id202_response.rb +224 -0
- data/lib/nutanix_volumes/models/update_iscsi_client_by_id4_xx_response.rb +224 -0
- data/lib/nutanix_volumes/models/update_volume_disk_by_id202_response.rb +224 -0
- data/lib/nutanix_volumes/models/update_volume_disk_by_id4_xx_response.rb +224 -0
- data/lib/nutanix_volumes/models/update_volume_group_by_id202_response.rb +224 -0
- data/lib/nutanix_volumes/models/update_volume_group_by_id4_xx_response.rb +224 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_associate_category_api_response.rb +224 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_attach_iscsi_client_api_response.rb +224 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_attach_nvmf_client_api_response.rb +224 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_attach_vm_api_response.rb +224 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_attachment_type.rb +43 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_authentication_type.rb +42 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_category_details.rb +344 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_category_entity_references.rb +246 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_cluster.rb +265 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_create_volume_disk_api_response.rb +224 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_create_volume_group_api_response.rb +224 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_delete_volume_disk_api_response.rb +224 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_delete_volume_group_api_response.rb +224 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_detach_iscsi_client_api_response.rb +224 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_detach_nvmf_client_api_response.rb +224 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_detach_vm_api_response.rb +224 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_disassociate_category_api_response.rb +224 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_disk_storage_features.rb +215 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_flash_mode.rb +218 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_get_iscsi_client_api_response.rb +224 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_get_iscsi_client_api_response_data.rb +105 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_get_volume_disk_api_response.rb +224 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_get_volume_disk_api_response_data.rb +105 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_get_volume_group_api_response.rb +224 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_get_volume_group_api_response_data.rb +105 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_get_volume_group_metadata_api_response.rb +224 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_get_volume_group_metadata_api_response_data.rb +105 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_iscsi_client.rb +508 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_iscsi_client_attachment.rb +268 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_iscsi_features.rb +275 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_list_category_associations_api_response.rb +224 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_list_category_associations_api_response_data.rb +105 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_list_external_iscsi_attachments_api_response.rb +224 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_list_external_iscsi_attachments_api_response_data.rb +105 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_list_iscsi_clients_api_response.rb +224 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_list_iscsi_clients_api_response_data.rb +105 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_list_vm_attachments_api_response.rb +224 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_list_vm_attachments_api_response_data.rb +105 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_list_volume_disks_api_response.rb +224 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_list_volume_disks_api_response_data.rb +105 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_list_volume_groups_api_response.rb +224 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_list_volume_groups_api_response_data.rb +105 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_migrate_volume_group_api_response.rb +224 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_nvmf_client.rb +412 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_nvmf_client_attachment.rb +343 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_pause_volume_group_synchronous_replication_api_response.rb +224 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_protocol.rb +43 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_resume_volume_group_synchronous_replication_api_response.rb +224 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_resume_volume_group_synchronous_replication_api_response_data.rb +104 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_revert_spec.rb +244 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_revert_volume_group_api_response.rb +224 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_sharing_status.rb +42 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_storage_features.rb +215 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_target_param.rb +273 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_update_iscsi_client_api_response.rb +224 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_update_iscsi_client_api_response_data.rb +105 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_update_iscsi_client_by_id_api_response.rb +224 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_update_volume_disk_api_response.rb +224 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_update_volume_disk_by_id_api_response.rb +224 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_update_volume_group_api_response.rb +224 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_update_volume_group_by_id_api_response.rb +224 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_update_volume_group_metadata_api_response.rb +224 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_update_volume_group_metadata_info_api_response.rb +224 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_usage_type.rb +44 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_vm_attachment.rb +254 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_volume_disk.rb +466 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_volume_group.rb +657 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_volume_group_attachment_site.rb +42 -0
- data/lib/nutanix_volumes/models/volumes_v40_config_volume_group_metadata.rb +255 -0
- data/lib/nutanix_volumes/models/volumes_v40_error_app_message.rb +291 -0
- data/lib/nutanix_volumes/models/volumes_v40_error_error_response.rb +215 -0
- data/lib/nutanix_volumes/models/volumes_v40_error_error_response_error.rb +105 -0
- data/lib/nutanix_volumes/models/volumes_v40_error_message_severity.rb +43 -0
- data/lib/nutanix_volumes/models/volumes_v40_error_schema_validation_error.rb +258 -0
- data/lib/nutanix_volumes/models/volumes_v40_error_schema_validation_error_message.rb +236 -0
- data/lib/nutanix_volumes/models/volumes_v40_stats_get_volume_disk_stats_api_response.rb +224 -0
- data/lib/nutanix_volumes/models/volumes_v40_stats_get_volume_disk_stats_api_response_data.rb +105 -0
- data/lib/nutanix_volumes/models/volumes_v40_stats_get_volume_group_stats_api_response.rb +224 -0
- data/lib/nutanix_volumes/models/volumes_v40_stats_get_volume_group_stats_api_response_data.rb +105 -0
- data/lib/nutanix_volumes/models/volumes_v40_stats_time_value_pair.rb +225 -0
- data/lib/nutanix_volumes/models/volumes_v40_stats_volume_disk_stats.rb +743 -0
- data/lib/nutanix_volumes/models/volumes_v40_stats_volume_group_stats.rb +743 -0
- data/lib/nutanix_volumes/version.rb +15 -0
- data/lib/nutanix_volumes.rb +194 -0
- data/nutanix_volumes.gemspec +39 -0
- data/spec/api/iscsi_clients_api_spec.rb +79 -0
- data/spec/api/volume_groups_api_spec.rb +370 -0
- data/spec/models/associate_category202_response_spec.rb +42 -0
- data/spec/models/associate_category4_xx_response_spec.rb +42 -0
- data/spec/models/attach_iscsi_client202_response_spec.rb +42 -0
- data/spec/models/attach_iscsi_client4_xx_response_spec.rb +42 -0
- data/spec/models/attach_vm202_response_spec.rb +42 -0
- data/spec/models/attach_vm4_xx_response_spec.rb +42 -0
- data/spec/models/common_v10_config_entity_reference_spec.rb +54 -0
- data/spec/models/common_v10_config_entity_type_spec.rb +30 -0
- data/spec/models/common_v10_config_flag_spec.rb +42 -0
- data/spec/models/common_v10_config_fqdn_spec.rb +36 -0
- data/spec/models/common_v10_config_ip_address_or_fqdn_spec.rb +48 -0
- data/spec/models/common_v10_config_ipv4_address_spec.rb +42 -0
- data/spec/models/common_v10_config_ipv6_address_spec.rb +42 -0
- data/spec/models/common_v10_config_kv_pair_spec.rb +42 -0
- data/spec/models/common_v10_config_kv_pair_value_spec.rb +32 -0
- data/spec/models/common_v10_config_map_of_string_wrapper_spec.rb +36 -0
- data/spec/models/common_v10_config_message_severity_spec.rb +30 -0
- data/spec/models/common_v10_config_message_spec.rb +54 -0
- data/spec/models/common_v10_config_metadata_spec.rb +60 -0
- data/spec/models/common_v10_config_tenant_aware_model_spec.rb +36 -0
- data/spec/models/common_v10_response_api_link_spec.rb +42 -0
- data/spec/models/common_v10_response_api_response_metadata_spec.rb +60 -0
- data/spec/models/common_v10_response_externalizable_abstract_model_spec.rb +48 -0
- data/spec/models/common_v10_stats_down_sampling_operator_spec.rb +30 -0
- data/spec/models/create_volume_disk202_response_spec.rb +42 -0
- data/spec/models/create_volume_disk4_xx_response_spec.rb +42 -0
- data/spec/models/create_volume_group202_response_spec.rb +42 -0
- data/spec/models/create_volume_group4_xx_response_spec.rb +42 -0
- data/spec/models/delete_volume_disk_by_id202_response_spec.rb +42 -0
- data/spec/models/delete_volume_disk_by_id4_xx_response_spec.rb +42 -0
- data/spec/models/delete_volume_group_by_id202_response_spec.rb +42 -0
- data/spec/models/delete_volume_group_by_id4_xx_response_spec.rb +42 -0
- data/spec/models/detach_iscsi_client202_response_spec.rb +42 -0
- data/spec/models/detach_iscsi_client4_xx_response_spec.rb +42 -0
- data/spec/models/detach_vm202_response_spec.rb +42 -0
- data/spec/models/detach_vm4_xx_response_spec.rb +42 -0
- data/spec/models/disassociate_category202_response_spec.rb +42 -0
- data/spec/models/disassociate_category4_xx_response_spec.rb +42 -0
- data/spec/models/get_iscsi_client_by_id200_response_spec.rb +42 -0
- data/spec/models/get_iscsi_client_by_id4_xx_response_spec.rb +42 -0
- data/spec/models/get_volume_disk_by_id200_response_spec.rb +42 -0
- data/spec/models/get_volume_disk_by_id4_xx_response_spec.rb +42 -0
- data/spec/models/get_volume_disk_stats200_response_spec.rb +42 -0
- data/spec/models/get_volume_disk_stats4_xx_response_spec.rb +42 -0
- data/spec/models/get_volume_group_by_id200_response_spec.rb +42 -0
- data/spec/models/get_volume_group_by_id4_xx_response_spec.rb +42 -0
- data/spec/models/get_volume_group_metadata_by_id200_response_spec.rb +42 -0
- data/spec/models/get_volume_group_metadata_by_id4_xx_response_spec.rb +42 -0
- data/spec/models/get_volume_group_stats200_response_spec.rb +42 -0
- data/spec/models/get_volume_group_stats4_xx_response_spec.rb +42 -0
- data/spec/models/list_category_associations_by_volume_group_id200_response_spec.rb +42 -0
- data/spec/models/list_category_associations_by_volume_group_id4_xx_response_spec.rb +42 -0
- data/spec/models/list_external_iscsi_attachments_by_volume_group_id200_response_spec.rb +42 -0
- data/spec/models/list_external_iscsi_attachments_by_volume_group_id4_xx_response_spec.rb +42 -0
- data/spec/models/list_iscsi_clients200_response_spec.rb +42 -0
- data/spec/models/list_iscsi_clients4_xx_response_spec.rb +42 -0
- data/spec/models/list_vm_attachments_by_volume_group_id200_response_spec.rb +42 -0
- data/spec/models/list_vm_attachments_by_volume_group_id4_xx_response_spec.rb +42 -0
- data/spec/models/list_volume_disks_by_volume_group_id200_response_spec.rb +42 -0
- data/spec/models/list_volume_disks_by_volume_group_id4_xx_response_spec.rb +42 -0
- data/spec/models/list_volume_groups200_response_spec.rb +42 -0
- data/spec/models/list_volume_groups4_xx_response_spec.rb +42 -0
- data/spec/models/prism_v40_config_task_reference_spec.rb +36 -0
- data/spec/models/revert_volume_group202_response_spec.rb +42 -0
- data/spec/models/revert_volume_group4_xx_response_spec.rb +42 -0
- data/spec/models/update_iscsi_client_by_id202_response_spec.rb +42 -0
- data/spec/models/update_iscsi_client_by_id4_xx_response_spec.rb +42 -0
- data/spec/models/update_volume_disk_by_id202_response_spec.rb +42 -0
- data/spec/models/update_volume_disk_by_id4_xx_response_spec.rb +42 -0
- data/spec/models/update_volume_group_by_id202_response_spec.rb +42 -0
- data/spec/models/update_volume_group_by_id4_xx_response_spec.rb +42 -0
- data/spec/models/volumes_v40_config_associate_category_api_response_spec.rb +42 -0
- data/spec/models/volumes_v40_config_attach_iscsi_client_api_response_spec.rb +42 -0
- data/spec/models/volumes_v40_config_attach_nvmf_client_api_response_spec.rb +42 -0
- data/spec/models/volumes_v40_config_attach_vm_api_response_spec.rb +42 -0
- data/spec/models/volumes_v40_config_attachment_type_spec.rb +30 -0
- data/spec/models/volumes_v40_config_authentication_type_spec.rb +30 -0
- data/spec/models/volumes_v40_config_category_details_spec.rb +54 -0
- data/spec/models/volumes_v40_config_category_entity_references_spec.rb +36 -0
- data/spec/models/volumes_v40_config_cluster_spec.rb +42 -0
- data/spec/models/volumes_v40_config_create_volume_disk_api_response_spec.rb +42 -0
- data/spec/models/volumes_v40_config_create_volume_group_api_response_spec.rb +42 -0
- data/spec/models/volumes_v40_config_delete_volume_disk_api_response_spec.rb +42 -0
- data/spec/models/volumes_v40_config_delete_volume_group_api_response_spec.rb +42 -0
- data/spec/models/volumes_v40_config_detach_iscsi_client_api_response_spec.rb +42 -0
- data/spec/models/volumes_v40_config_detach_nvmf_client_api_response_spec.rb +42 -0
- data/spec/models/volumes_v40_config_detach_vm_api_response_spec.rb +42 -0
- data/spec/models/volumes_v40_config_disassociate_category_api_response_spec.rb +42 -0
- data/spec/models/volumes_v40_config_disk_storage_features_spec.rb +36 -0
- data/spec/models/volumes_v40_config_flash_mode_spec.rb +36 -0
- data/spec/models/volumes_v40_config_get_iscsi_client_api_response_data_spec.rb +32 -0
- data/spec/models/volumes_v40_config_get_iscsi_client_api_response_spec.rb +42 -0
- data/spec/models/volumes_v40_config_get_volume_disk_api_response_data_spec.rb +32 -0
- data/spec/models/volumes_v40_config_get_volume_disk_api_response_spec.rb +42 -0
- data/spec/models/volumes_v40_config_get_volume_group_api_response_data_spec.rb +32 -0
- data/spec/models/volumes_v40_config_get_volume_group_api_response_spec.rb +42 -0
- data/spec/models/volumes_v40_config_get_volume_group_metadata_api_response_data_spec.rb +32 -0
- data/spec/models/volumes_v40_config_get_volume_group_metadata_api_response_spec.rb +42 -0
- data/spec/models/volumes_v40_config_iscsi_client_attachment_spec.rb +42 -0
- data/spec/models/volumes_v40_config_iscsi_client_spec.rb +96 -0
- data/spec/models/volumes_v40_config_iscsi_features_spec.rb +42 -0
- data/spec/models/volumes_v40_config_list_category_associations_api_response_data_spec.rb +32 -0
- data/spec/models/volumes_v40_config_list_category_associations_api_response_spec.rb +42 -0
- data/spec/models/volumes_v40_config_list_external_iscsi_attachments_api_response_data_spec.rb +32 -0
- data/spec/models/volumes_v40_config_list_external_iscsi_attachments_api_response_spec.rb +42 -0
- data/spec/models/volumes_v40_config_list_iscsi_clients_api_response_data_spec.rb +32 -0
- data/spec/models/volumes_v40_config_list_iscsi_clients_api_response_spec.rb +42 -0
- data/spec/models/volumes_v40_config_list_vm_attachments_api_response_data_spec.rb +32 -0
- data/spec/models/volumes_v40_config_list_vm_attachments_api_response_spec.rb +42 -0
- data/spec/models/volumes_v40_config_list_volume_disks_api_response_data_spec.rb +32 -0
- data/spec/models/volumes_v40_config_list_volume_disks_api_response_spec.rb +42 -0
- data/spec/models/volumes_v40_config_list_volume_groups_api_response_data_spec.rb +32 -0
- data/spec/models/volumes_v40_config_list_volume_groups_api_response_spec.rb +42 -0
- data/spec/models/volumes_v40_config_migrate_volume_group_api_response_spec.rb +42 -0
- data/spec/models/volumes_v40_config_nvmf_client_attachment_spec.rb +54 -0
- data/spec/models/volumes_v40_config_nvmf_client_spec.rb +66 -0
- data/spec/models/volumes_v40_config_pause_volume_group_synchronous_replication_api_response_spec.rb +42 -0
- data/spec/models/volumes_v40_config_protocol_spec.rb +30 -0
- data/spec/models/volumes_v40_config_resume_volume_group_synchronous_replication_api_response_data_spec.rb +32 -0
- data/spec/models/volumes_v40_config_resume_volume_group_synchronous_replication_api_response_spec.rb +42 -0
- data/spec/models/volumes_v40_config_revert_spec_spec.rb +36 -0
- data/spec/models/volumes_v40_config_revert_volume_group_api_response_spec.rb +42 -0
- data/spec/models/volumes_v40_config_sharing_status_spec.rb +30 -0
- data/spec/models/volumes_v40_config_storage_features_spec.rb +36 -0
- data/spec/models/volumes_v40_config_target_param_spec.rb +42 -0
- data/spec/models/volumes_v40_config_update_iscsi_client_api_response_data_spec.rb +32 -0
- data/spec/models/volumes_v40_config_update_iscsi_client_api_response_spec.rb +42 -0
- data/spec/models/volumes_v40_config_update_iscsi_client_by_id_api_response_spec.rb +42 -0
- data/spec/models/volumes_v40_config_update_volume_disk_api_response_spec.rb +42 -0
- data/spec/models/volumes_v40_config_update_volume_disk_by_id_api_response_spec.rb +42 -0
- data/spec/models/volumes_v40_config_update_volume_group_api_response_spec.rb +42 -0
- data/spec/models/volumes_v40_config_update_volume_group_by_id_api_response_spec.rb +42 -0
- data/spec/models/volumes_v40_config_update_volume_group_metadata_api_response_spec.rb +42 -0
- data/spec/models/volumes_v40_config_update_volume_group_metadata_info_api_response_spec.rb +42 -0
- data/spec/models/volumes_v40_config_usage_type_spec.rb +30 -0
- data/spec/models/volumes_v40_config_vm_attachment_spec.rb +42 -0
- data/spec/models/volumes_v40_config_volume_disk_spec.rb +84 -0
- data/spec/models/volumes_v40_config_volume_group_attachment_site_spec.rb +30 -0
- data/spec/models/volumes_v40_config_volume_group_metadata_spec.rb +42 -0
- data/spec/models/volumes_v40_config_volume_group_spec.rb +144 -0
- data/spec/models/volumes_v40_error_app_message_spec.rb +66 -0
- data/spec/models/volumes_v40_error_error_response_error_spec.rb +32 -0
- data/spec/models/volumes_v40_error_error_response_spec.rb +36 -0
- data/spec/models/volumes_v40_error_message_severity_spec.rb +30 -0
- data/spec/models/volumes_v40_error_schema_validation_error_message_spec.rb +48 -0
- data/spec/models/volumes_v40_error_schema_validation_error_spec.rb +60 -0
- data/spec/models/volumes_v40_stats_get_volume_disk_stats_api_response_data_spec.rb +32 -0
- data/spec/models/volumes_v40_stats_get_volume_disk_stats_api_response_spec.rb +42 -0
- data/spec/models/volumes_v40_stats_get_volume_group_stats_api_response_data_spec.rb +32 -0
- data/spec/models/volumes_v40_stats_get_volume_group_stats_api_response_spec.rb +42 -0
- data/spec/models/volumes_v40_stats_time_value_pair_spec.rb +42 -0
- data/spec/models/volumes_v40_stats_volume_disk_stats_spec.rb +114 -0
- data/spec/models/volumes_v40_stats_volume_group_stats_spec.rb +114 -0
- data/spec/spec_helper.rb +111 -0
- data/swagger-volumes-v4.0-all.yaml +8140 -0
- metadata +714 -0
|
@@ -0,0 +1,2003 @@
|
|
|
1
|
+
=begin
|
|
2
|
+
#Nutanix Volumes APIs
|
|
3
|
+
|
|
4
|
+
#Configure volumes.
|
|
5
|
+
|
|
6
|
+
The version of the OpenAPI document: 4.0
|
|
7
|
+
|
|
8
|
+
Generated by: https://openapi-generator.tech
|
|
9
|
+
Generator version: 7.9.0
|
|
10
|
+
|
|
11
|
+
=end
|
|
12
|
+
|
|
13
|
+
require 'cgi'
|
|
14
|
+
|
|
15
|
+
module NutanixVolumes
|
|
16
|
+
class VolumeGroupsApi
|
|
17
|
+
attr_accessor :api_client
|
|
18
|
+
|
|
19
|
+
def initialize(api_client = ApiClient.default)
|
|
20
|
+
@api_client = api_client
|
|
21
|
+
end
|
|
22
|
+
# Associate category to a Volume Group
|
|
23
|
+
# Associates a category to a Volume Group identified by {extId}.
|
|
24
|
+
# @param ext_id [String] The external identifier of a Volume Group.
|
|
25
|
+
# @param volumes_v40_config_category_entity_references [VolumesV40ConfigCategoryEntityReferences] The list of categories to be associated/disassociated with the Volume Group. This is a mandatory field.
|
|
26
|
+
# @param [Hash] opts the optional parameters
|
|
27
|
+
# @return [AssociateCategory202Response]
|
|
28
|
+
def associate_category(ext_id, volumes_v40_config_category_entity_references, opts = {})
|
|
29
|
+
data, _status_code, _headers = associate_category_with_http_info(ext_id, volumes_v40_config_category_entity_references, opts)
|
|
30
|
+
data
|
|
31
|
+
end
|
|
32
|
+
|
|
33
|
+
# Associate category to a Volume Group
|
|
34
|
+
# Associates a category to a Volume Group identified by {extId}.
|
|
35
|
+
# @param ext_id [String] The external identifier of a Volume Group.
|
|
36
|
+
# @param volumes_v40_config_category_entity_references [VolumesV40ConfigCategoryEntityReferences] The list of categories to be associated/disassociated with the Volume Group. This is a mandatory field.
|
|
37
|
+
# @param [Hash] opts the optional parameters
|
|
38
|
+
# @return [Array<(AssociateCategory202Response, Integer, Hash)>] AssociateCategory202Response data, response status code and response headers
|
|
39
|
+
def associate_category_with_http_info(ext_id, volumes_v40_config_category_entity_references, opts = {})
|
|
40
|
+
if @api_client.config.debugging
|
|
41
|
+
@api_client.config.logger.debug 'Calling API: VolumeGroupsApi.associate_category ...'
|
|
42
|
+
end
|
|
43
|
+
# verify the required parameter 'ext_id' is set
|
|
44
|
+
if @api_client.config.client_side_validation && ext_id.nil?
|
|
45
|
+
fail ArgumentError, "Missing the required parameter 'ext_id' when calling VolumeGroupsApi.associate_category"
|
|
46
|
+
end
|
|
47
|
+
pattern = Regexp.new(/^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$/)
|
|
48
|
+
if @api_client.config.client_side_validation && ext_id !~ pattern
|
|
49
|
+
fail ArgumentError, "invalid value for 'ext_id' when calling VolumeGroupsApi.associate_category, must conform to the pattern #{pattern}."
|
|
50
|
+
end
|
|
51
|
+
|
|
52
|
+
# verify the required parameter 'volumes_v40_config_category_entity_references' is set
|
|
53
|
+
if @api_client.config.client_side_validation && volumes_v40_config_category_entity_references.nil?
|
|
54
|
+
fail ArgumentError, "Missing the required parameter 'volumes_v40_config_category_entity_references' when calling VolumeGroupsApi.associate_category"
|
|
55
|
+
end
|
|
56
|
+
# resource path
|
|
57
|
+
local_var_path = '/volumes/v4.0/config/volume-groups/{extId}/$actions/associate-category'.sub('{' + 'extId' + '}', CGI.escape(ext_id.to_s))
|
|
58
|
+
|
|
59
|
+
# query parameters
|
|
60
|
+
query_params = opts[:query_params] || {}
|
|
61
|
+
|
|
62
|
+
# header parameters
|
|
63
|
+
header_params = opts[:header_params] || {}
|
|
64
|
+
# HTTP header 'Accept' (if needed)
|
|
65
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
66
|
+
# HTTP header 'Content-Type'
|
|
67
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
|
68
|
+
if !content_type.nil?
|
|
69
|
+
header_params['Content-Type'] = content_type
|
|
70
|
+
end
|
|
71
|
+
|
|
72
|
+
# form parameters
|
|
73
|
+
form_params = opts[:form_params] || {}
|
|
74
|
+
|
|
75
|
+
# http body (model)
|
|
76
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(volumes_v40_config_category_entity_references)
|
|
77
|
+
|
|
78
|
+
# return_type
|
|
79
|
+
return_type = opts[:debug_return_type] || 'AssociateCategory202Response'
|
|
80
|
+
|
|
81
|
+
# auth_names
|
|
82
|
+
auth_names = opts[:debug_auth_names] || ['apiKeyAuthScheme', 'basicAuthScheme']
|
|
83
|
+
|
|
84
|
+
new_options = opts.merge(
|
|
85
|
+
:operation => :"VolumeGroupsApi.associate_category",
|
|
86
|
+
:header_params => header_params,
|
|
87
|
+
:query_params => query_params,
|
|
88
|
+
:form_params => form_params,
|
|
89
|
+
:body => post_body,
|
|
90
|
+
:auth_names => auth_names,
|
|
91
|
+
:return_type => return_type
|
|
92
|
+
)
|
|
93
|
+
|
|
94
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
|
95
|
+
if @api_client.config.debugging
|
|
96
|
+
@api_client.config.logger.debug "API called: VolumeGroupsApi#associate_category\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
97
|
+
end
|
|
98
|
+
return data, status_code, headers
|
|
99
|
+
end
|
|
100
|
+
|
|
101
|
+
# Attach an iSCSI client to the given Volume Group
|
|
102
|
+
# Attaches iSCSI initiator to a Volume Group identified by {extId}.
|
|
103
|
+
# @param ext_id [String] The external identifier of a Volume Group.
|
|
104
|
+
# @param ntnx_request_id [String] A unique identifier that is associated with each request. The provided value must be opaque and preferably in Universal Unique Identifier (UUID) format. This identifier is also used as an idempotence token for safely retrying requests in case of network errors. All the supported Nutanix API clients add this auto-generated request identifier to each request.
|
|
105
|
+
# @param volumes_v40_config_iscsi_client [VolumesV40ConfigIscsiClient] A model that represents an iSCSI client that can be associated with a Volume Group as an external attachment.
|
|
106
|
+
# @param [Hash] opts the optional parameters
|
|
107
|
+
# @return [AttachIscsiClient202Response]
|
|
108
|
+
def attach_iscsi_client(ext_id, ntnx_request_id, volumes_v40_config_iscsi_client, opts = {})
|
|
109
|
+
data, _status_code, _headers = attach_iscsi_client_with_http_info(ext_id, ntnx_request_id, volumes_v40_config_iscsi_client, opts)
|
|
110
|
+
data
|
|
111
|
+
end
|
|
112
|
+
|
|
113
|
+
# Attach an iSCSI client to the given Volume Group
|
|
114
|
+
# Attaches iSCSI initiator to a Volume Group identified by {extId}.
|
|
115
|
+
# @param ext_id [String] The external identifier of a Volume Group.
|
|
116
|
+
# @param ntnx_request_id [String] A unique identifier that is associated with each request. The provided value must be opaque and preferably in Universal Unique Identifier (UUID) format. This identifier is also used as an idempotence token for safely retrying requests in case of network errors. All the supported Nutanix API clients add this auto-generated request identifier to each request.
|
|
117
|
+
# @param volumes_v40_config_iscsi_client [VolumesV40ConfigIscsiClient] A model that represents an iSCSI client that can be associated with a Volume Group as an external attachment.
|
|
118
|
+
# @param [Hash] opts the optional parameters
|
|
119
|
+
# @return [Array<(AttachIscsiClient202Response, Integer, Hash)>] AttachIscsiClient202Response data, response status code and response headers
|
|
120
|
+
def attach_iscsi_client_with_http_info(ext_id, ntnx_request_id, volumes_v40_config_iscsi_client, opts = {})
|
|
121
|
+
if @api_client.config.debugging
|
|
122
|
+
@api_client.config.logger.debug 'Calling API: VolumeGroupsApi.attach_iscsi_client ...'
|
|
123
|
+
end
|
|
124
|
+
# verify the required parameter 'ext_id' is set
|
|
125
|
+
if @api_client.config.client_side_validation && ext_id.nil?
|
|
126
|
+
fail ArgumentError, "Missing the required parameter 'ext_id' when calling VolumeGroupsApi.attach_iscsi_client"
|
|
127
|
+
end
|
|
128
|
+
pattern = Regexp.new(/^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$/)
|
|
129
|
+
if @api_client.config.client_side_validation && ext_id !~ pattern
|
|
130
|
+
fail ArgumentError, "invalid value for 'ext_id' when calling VolumeGroupsApi.attach_iscsi_client, must conform to the pattern #{pattern}."
|
|
131
|
+
end
|
|
132
|
+
|
|
133
|
+
# verify the required parameter 'ntnx_request_id' is set
|
|
134
|
+
if @api_client.config.client_side_validation && ntnx_request_id.nil?
|
|
135
|
+
fail ArgumentError, "Missing the required parameter 'ntnx_request_id' when calling VolumeGroupsApi.attach_iscsi_client"
|
|
136
|
+
end
|
|
137
|
+
# verify the required parameter 'volumes_v40_config_iscsi_client' is set
|
|
138
|
+
if @api_client.config.client_side_validation && volumes_v40_config_iscsi_client.nil?
|
|
139
|
+
fail ArgumentError, "Missing the required parameter 'volumes_v40_config_iscsi_client' when calling VolumeGroupsApi.attach_iscsi_client"
|
|
140
|
+
end
|
|
141
|
+
# resource path
|
|
142
|
+
local_var_path = '/volumes/v4.0/config/volume-groups/{extId}/$actions/attach-iscsi-client'.sub('{' + 'extId' + '}', CGI.escape(ext_id.to_s))
|
|
143
|
+
|
|
144
|
+
# query parameters
|
|
145
|
+
query_params = opts[:query_params] || {}
|
|
146
|
+
|
|
147
|
+
# header parameters
|
|
148
|
+
header_params = opts[:header_params] || {}
|
|
149
|
+
# HTTP header 'Accept' (if needed)
|
|
150
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
151
|
+
# HTTP header 'Content-Type'
|
|
152
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
|
153
|
+
if !content_type.nil?
|
|
154
|
+
header_params['Content-Type'] = content_type
|
|
155
|
+
end
|
|
156
|
+
header_params[:'NTNX-Request-Id'] = ntnx_request_id
|
|
157
|
+
|
|
158
|
+
# form parameters
|
|
159
|
+
form_params = opts[:form_params] || {}
|
|
160
|
+
|
|
161
|
+
# http body (model)
|
|
162
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(volumes_v40_config_iscsi_client)
|
|
163
|
+
|
|
164
|
+
# return_type
|
|
165
|
+
return_type = opts[:debug_return_type] || 'AttachIscsiClient202Response'
|
|
166
|
+
|
|
167
|
+
# auth_names
|
|
168
|
+
auth_names = opts[:debug_auth_names] || ['apiKeyAuthScheme', 'basicAuthScheme']
|
|
169
|
+
|
|
170
|
+
new_options = opts.merge(
|
|
171
|
+
:operation => :"VolumeGroupsApi.attach_iscsi_client",
|
|
172
|
+
:header_params => header_params,
|
|
173
|
+
:query_params => query_params,
|
|
174
|
+
:form_params => form_params,
|
|
175
|
+
:body => post_body,
|
|
176
|
+
:auth_names => auth_names,
|
|
177
|
+
:return_type => return_type
|
|
178
|
+
)
|
|
179
|
+
|
|
180
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
|
181
|
+
if @api_client.config.debugging
|
|
182
|
+
@api_client.config.logger.debug "API called: VolumeGroupsApi#attach_iscsi_client\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
183
|
+
end
|
|
184
|
+
return data, status_code, headers
|
|
185
|
+
end
|
|
186
|
+
|
|
187
|
+
# Attach an AHV VM to the given Volume Group
|
|
188
|
+
# Attaches VM to a Volume Group identified by {extId}.
|
|
189
|
+
# @param ext_id [String] The external identifier of a Volume Group.
|
|
190
|
+
# @param ntnx_request_id [String] A unique identifier that is associated with each request. The provided value must be opaque and preferably in Universal Unique Identifier (UUID) format. This identifier is also used as an idempotence token for safely retrying requests in case of network errors. All the supported Nutanix API clients add this auto-generated request identifier to each request.
|
|
191
|
+
# @param volumes_v40_config_vm_attachment [VolumesV40ConfigVmAttachment] A model that represents a VM reference that can be associated with a Volume Group as an AHV hypervisor attachment.
|
|
192
|
+
# @param [Hash] opts the optional parameters
|
|
193
|
+
# @return [AttachVm202Response]
|
|
194
|
+
def attach_vm(ext_id, ntnx_request_id, volumes_v40_config_vm_attachment, opts = {})
|
|
195
|
+
data, _status_code, _headers = attach_vm_with_http_info(ext_id, ntnx_request_id, volumes_v40_config_vm_attachment, opts)
|
|
196
|
+
data
|
|
197
|
+
end
|
|
198
|
+
|
|
199
|
+
# Attach an AHV VM to the given Volume Group
|
|
200
|
+
# Attaches VM to a Volume Group identified by {extId}.
|
|
201
|
+
# @param ext_id [String] The external identifier of a Volume Group.
|
|
202
|
+
# @param ntnx_request_id [String] A unique identifier that is associated with each request. The provided value must be opaque and preferably in Universal Unique Identifier (UUID) format. This identifier is also used as an idempotence token for safely retrying requests in case of network errors. All the supported Nutanix API clients add this auto-generated request identifier to each request.
|
|
203
|
+
# @param volumes_v40_config_vm_attachment [VolumesV40ConfigVmAttachment] A model that represents a VM reference that can be associated with a Volume Group as an AHV hypervisor attachment.
|
|
204
|
+
# @param [Hash] opts the optional parameters
|
|
205
|
+
# @return [Array<(AttachVm202Response, Integer, Hash)>] AttachVm202Response data, response status code and response headers
|
|
206
|
+
def attach_vm_with_http_info(ext_id, ntnx_request_id, volumes_v40_config_vm_attachment, opts = {})
|
|
207
|
+
if @api_client.config.debugging
|
|
208
|
+
@api_client.config.logger.debug 'Calling API: VolumeGroupsApi.attach_vm ...'
|
|
209
|
+
end
|
|
210
|
+
# verify the required parameter 'ext_id' is set
|
|
211
|
+
if @api_client.config.client_side_validation && ext_id.nil?
|
|
212
|
+
fail ArgumentError, "Missing the required parameter 'ext_id' when calling VolumeGroupsApi.attach_vm"
|
|
213
|
+
end
|
|
214
|
+
pattern = Regexp.new(/^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$/)
|
|
215
|
+
if @api_client.config.client_side_validation && ext_id !~ pattern
|
|
216
|
+
fail ArgumentError, "invalid value for 'ext_id' when calling VolumeGroupsApi.attach_vm, must conform to the pattern #{pattern}."
|
|
217
|
+
end
|
|
218
|
+
|
|
219
|
+
# verify the required parameter 'ntnx_request_id' is set
|
|
220
|
+
if @api_client.config.client_side_validation && ntnx_request_id.nil?
|
|
221
|
+
fail ArgumentError, "Missing the required parameter 'ntnx_request_id' when calling VolumeGroupsApi.attach_vm"
|
|
222
|
+
end
|
|
223
|
+
# verify the required parameter 'volumes_v40_config_vm_attachment' is set
|
|
224
|
+
if @api_client.config.client_side_validation && volumes_v40_config_vm_attachment.nil?
|
|
225
|
+
fail ArgumentError, "Missing the required parameter 'volumes_v40_config_vm_attachment' when calling VolumeGroupsApi.attach_vm"
|
|
226
|
+
end
|
|
227
|
+
# resource path
|
|
228
|
+
local_var_path = '/volumes/v4.0/config/volume-groups/{extId}/$actions/attach-vm'.sub('{' + 'extId' + '}', CGI.escape(ext_id.to_s))
|
|
229
|
+
|
|
230
|
+
# query parameters
|
|
231
|
+
query_params = opts[:query_params] || {}
|
|
232
|
+
|
|
233
|
+
# header parameters
|
|
234
|
+
header_params = opts[:header_params] || {}
|
|
235
|
+
# HTTP header 'Accept' (if needed)
|
|
236
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
237
|
+
# HTTP header 'Content-Type'
|
|
238
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
|
239
|
+
if !content_type.nil?
|
|
240
|
+
header_params['Content-Type'] = content_type
|
|
241
|
+
end
|
|
242
|
+
header_params[:'NTNX-Request-Id'] = ntnx_request_id
|
|
243
|
+
|
|
244
|
+
# form parameters
|
|
245
|
+
form_params = opts[:form_params] || {}
|
|
246
|
+
|
|
247
|
+
# http body (model)
|
|
248
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(volumes_v40_config_vm_attachment)
|
|
249
|
+
|
|
250
|
+
# return_type
|
|
251
|
+
return_type = opts[:debug_return_type] || 'AttachVm202Response'
|
|
252
|
+
|
|
253
|
+
# auth_names
|
|
254
|
+
auth_names = opts[:debug_auth_names] || ['apiKeyAuthScheme', 'basicAuthScheme']
|
|
255
|
+
|
|
256
|
+
new_options = opts.merge(
|
|
257
|
+
:operation => :"VolumeGroupsApi.attach_vm",
|
|
258
|
+
:header_params => header_params,
|
|
259
|
+
:query_params => query_params,
|
|
260
|
+
:form_params => form_params,
|
|
261
|
+
:body => post_body,
|
|
262
|
+
:auth_names => auth_names,
|
|
263
|
+
:return_type => return_type
|
|
264
|
+
)
|
|
265
|
+
|
|
266
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
|
267
|
+
if @api_client.config.debugging
|
|
268
|
+
@api_client.config.logger.debug "API called: VolumeGroupsApi#attach_vm\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
269
|
+
end
|
|
270
|
+
return data, status_code, headers
|
|
271
|
+
end
|
|
272
|
+
|
|
273
|
+
# Creates a new Volume Disk
|
|
274
|
+
# Creates a new Volume Disk.
|
|
275
|
+
# @param volume_group_ext_id [String] The external identifier of a Volume Group.
|
|
276
|
+
# @param ntnx_request_id [String] A unique identifier that is associated with each request. The provided value must be opaque and preferably in Universal Unique Identifier (UUID) format. This identifier is also used as an idempotence token for safely retrying requests in case of network errors. All the supported Nutanix API clients add this auto-generated request identifier to each request.
|
|
277
|
+
# @param volumes_v40_config_volume_disk [VolumesV40ConfigVolumeDisk] A model that represents a Volume Disk associated with a Volume Group, supported by a backing file on DSF.
|
|
278
|
+
# @param [Hash] opts the optional parameters
|
|
279
|
+
# @return [CreateVolumeDisk202Response]
|
|
280
|
+
def create_volume_disk(volume_group_ext_id, ntnx_request_id, volumes_v40_config_volume_disk, opts = {})
|
|
281
|
+
data, _status_code, _headers = create_volume_disk_with_http_info(volume_group_ext_id, ntnx_request_id, volumes_v40_config_volume_disk, opts)
|
|
282
|
+
data
|
|
283
|
+
end
|
|
284
|
+
|
|
285
|
+
# Creates a new Volume Disk
|
|
286
|
+
# Creates a new Volume Disk.
|
|
287
|
+
# @param volume_group_ext_id [String] The external identifier of a Volume Group.
|
|
288
|
+
# @param ntnx_request_id [String] A unique identifier that is associated with each request. The provided value must be opaque and preferably in Universal Unique Identifier (UUID) format. This identifier is also used as an idempotence token for safely retrying requests in case of network errors. All the supported Nutanix API clients add this auto-generated request identifier to each request.
|
|
289
|
+
# @param volumes_v40_config_volume_disk [VolumesV40ConfigVolumeDisk] A model that represents a Volume Disk associated with a Volume Group, supported by a backing file on DSF.
|
|
290
|
+
# @param [Hash] opts the optional parameters
|
|
291
|
+
# @return [Array<(CreateVolumeDisk202Response, Integer, Hash)>] CreateVolumeDisk202Response data, response status code and response headers
|
|
292
|
+
def create_volume_disk_with_http_info(volume_group_ext_id, ntnx_request_id, volumes_v40_config_volume_disk, opts = {})
|
|
293
|
+
if @api_client.config.debugging
|
|
294
|
+
@api_client.config.logger.debug 'Calling API: VolumeGroupsApi.create_volume_disk ...'
|
|
295
|
+
end
|
|
296
|
+
# verify the required parameter 'volume_group_ext_id' is set
|
|
297
|
+
if @api_client.config.client_side_validation && volume_group_ext_id.nil?
|
|
298
|
+
fail ArgumentError, "Missing the required parameter 'volume_group_ext_id' when calling VolumeGroupsApi.create_volume_disk"
|
|
299
|
+
end
|
|
300
|
+
pattern = Regexp.new(/^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$/)
|
|
301
|
+
if @api_client.config.client_side_validation && volume_group_ext_id !~ pattern
|
|
302
|
+
fail ArgumentError, "invalid value for 'volume_group_ext_id' when calling VolumeGroupsApi.create_volume_disk, must conform to the pattern #{pattern}."
|
|
303
|
+
end
|
|
304
|
+
|
|
305
|
+
# verify the required parameter 'ntnx_request_id' is set
|
|
306
|
+
if @api_client.config.client_side_validation && ntnx_request_id.nil?
|
|
307
|
+
fail ArgumentError, "Missing the required parameter 'ntnx_request_id' when calling VolumeGroupsApi.create_volume_disk"
|
|
308
|
+
end
|
|
309
|
+
# verify the required parameter 'volumes_v40_config_volume_disk' is set
|
|
310
|
+
if @api_client.config.client_side_validation && volumes_v40_config_volume_disk.nil?
|
|
311
|
+
fail ArgumentError, "Missing the required parameter 'volumes_v40_config_volume_disk' when calling VolumeGroupsApi.create_volume_disk"
|
|
312
|
+
end
|
|
313
|
+
# resource path
|
|
314
|
+
local_var_path = '/volumes/v4.0/config/volume-groups/{volumeGroupExtId}/disks'.sub('{' + 'volumeGroupExtId' + '}', CGI.escape(volume_group_ext_id.to_s))
|
|
315
|
+
|
|
316
|
+
# query parameters
|
|
317
|
+
query_params = opts[:query_params] || {}
|
|
318
|
+
|
|
319
|
+
# header parameters
|
|
320
|
+
header_params = opts[:header_params] || {}
|
|
321
|
+
# HTTP header 'Accept' (if needed)
|
|
322
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
323
|
+
# HTTP header 'Content-Type'
|
|
324
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
|
325
|
+
if !content_type.nil?
|
|
326
|
+
header_params['Content-Type'] = content_type
|
|
327
|
+
end
|
|
328
|
+
header_params[:'NTNX-Request-Id'] = ntnx_request_id
|
|
329
|
+
|
|
330
|
+
# form parameters
|
|
331
|
+
form_params = opts[:form_params] || {}
|
|
332
|
+
|
|
333
|
+
# http body (model)
|
|
334
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(volumes_v40_config_volume_disk)
|
|
335
|
+
|
|
336
|
+
# return_type
|
|
337
|
+
return_type = opts[:debug_return_type] || 'CreateVolumeDisk202Response'
|
|
338
|
+
|
|
339
|
+
# auth_names
|
|
340
|
+
auth_names = opts[:debug_auth_names] || ['apiKeyAuthScheme', 'basicAuthScheme']
|
|
341
|
+
|
|
342
|
+
new_options = opts.merge(
|
|
343
|
+
:operation => :"VolumeGroupsApi.create_volume_disk",
|
|
344
|
+
:header_params => header_params,
|
|
345
|
+
:query_params => query_params,
|
|
346
|
+
:form_params => form_params,
|
|
347
|
+
:body => post_body,
|
|
348
|
+
:auth_names => auth_names,
|
|
349
|
+
:return_type => return_type
|
|
350
|
+
)
|
|
351
|
+
|
|
352
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
|
353
|
+
if @api_client.config.debugging
|
|
354
|
+
@api_client.config.logger.debug "API called: VolumeGroupsApi#create_volume_disk\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
355
|
+
end
|
|
356
|
+
return data, status_code, headers
|
|
357
|
+
end
|
|
358
|
+
|
|
359
|
+
# Creates a new Volume Group
|
|
360
|
+
# Creates a new Volume Group.
|
|
361
|
+
# @param ntnx_request_id [String] A unique identifier that is associated with each request. The provided value must be opaque and preferably in Universal Unique Identifier (UUID) format. This identifier is also used as an idempotence token for safely retrying requests in case of network errors. All the supported Nutanix API clients add this auto-generated request identifier to each request.
|
|
362
|
+
# @param volumes_v40_config_volume_group [VolumesV40ConfigVolumeGroup] A model that represents a Volume Group resource.
|
|
363
|
+
# @param [Hash] opts the optional parameters
|
|
364
|
+
# @return [CreateVolumeGroup202Response]
|
|
365
|
+
def create_volume_group(ntnx_request_id, volumes_v40_config_volume_group, opts = {})
|
|
366
|
+
data, _status_code, _headers = create_volume_group_with_http_info(ntnx_request_id, volumes_v40_config_volume_group, opts)
|
|
367
|
+
data
|
|
368
|
+
end
|
|
369
|
+
|
|
370
|
+
# Creates a new Volume Group
|
|
371
|
+
# Creates a new Volume Group.
|
|
372
|
+
# @param ntnx_request_id [String] A unique identifier that is associated with each request. The provided value must be opaque and preferably in Universal Unique Identifier (UUID) format. This identifier is also used as an idempotence token for safely retrying requests in case of network errors. All the supported Nutanix API clients add this auto-generated request identifier to each request.
|
|
373
|
+
# @param volumes_v40_config_volume_group [VolumesV40ConfigVolumeGroup] A model that represents a Volume Group resource.
|
|
374
|
+
# @param [Hash] opts the optional parameters
|
|
375
|
+
# @return [Array<(CreateVolumeGroup202Response, Integer, Hash)>] CreateVolumeGroup202Response data, response status code and response headers
|
|
376
|
+
def create_volume_group_with_http_info(ntnx_request_id, volumes_v40_config_volume_group, opts = {})
|
|
377
|
+
if @api_client.config.debugging
|
|
378
|
+
@api_client.config.logger.debug 'Calling API: VolumeGroupsApi.create_volume_group ...'
|
|
379
|
+
end
|
|
380
|
+
# verify the required parameter 'ntnx_request_id' is set
|
|
381
|
+
if @api_client.config.client_side_validation && ntnx_request_id.nil?
|
|
382
|
+
fail ArgumentError, "Missing the required parameter 'ntnx_request_id' when calling VolumeGroupsApi.create_volume_group"
|
|
383
|
+
end
|
|
384
|
+
# verify the required parameter 'volumes_v40_config_volume_group' is set
|
|
385
|
+
if @api_client.config.client_side_validation && volumes_v40_config_volume_group.nil?
|
|
386
|
+
fail ArgumentError, "Missing the required parameter 'volumes_v40_config_volume_group' when calling VolumeGroupsApi.create_volume_group"
|
|
387
|
+
end
|
|
388
|
+
# resource path
|
|
389
|
+
local_var_path = '/volumes/v4.0/config/volume-groups'
|
|
390
|
+
|
|
391
|
+
# query parameters
|
|
392
|
+
query_params = opts[:query_params] || {}
|
|
393
|
+
|
|
394
|
+
# header parameters
|
|
395
|
+
header_params = opts[:header_params] || {}
|
|
396
|
+
# HTTP header 'Accept' (if needed)
|
|
397
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
398
|
+
# HTTP header 'Content-Type'
|
|
399
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
|
400
|
+
if !content_type.nil?
|
|
401
|
+
header_params['Content-Type'] = content_type
|
|
402
|
+
end
|
|
403
|
+
header_params[:'NTNX-Request-Id'] = ntnx_request_id
|
|
404
|
+
|
|
405
|
+
# form parameters
|
|
406
|
+
form_params = opts[:form_params] || {}
|
|
407
|
+
|
|
408
|
+
# http body (model)
|
|
409
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(volumes_v40_config_volume_group)
|
|
410
|
+
|
|
411
|
+
# return_type
|
|
412
|
+
return_type = opts[:debug_return_type] || 'CreateVolumeGroup202Response'
|
|
413
|
+
|
|
414
|
+
# auth_names
|
|
415
|
+
auth_names = opts[:debug_auth_names] || ['apiKeyAuthScheme', 'basicAuthScheme']
|
|
416
|
+
|
|
417
|
+
new_options = opts.merge(
|
|
418
|
+
:operation => :"VolumeGroupsApi.create_volume_group",
|
|
419
|
+
:header_params => header_params,
|
|
420
|
+
:query_params => query_params,
|
|
421
|
+
:form_params => form_params,
|
|
422
|
+
:body => post_body,
|
|
423
|
+
:auth_names => auth_names,
|
|
424
|
+
:return_type => return_type
|
|
425
|
+
)
|
|
426
|
+
|
|
427
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
|
428
|
+
if @api_client.config.debugging
|
|
429
|
+
@api_client.config.logger.debug "API called: VolumeGroupsApi#create_volume_group\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
430
|
+
end
|
|
431
|
+
return data, status_code, headers
|
|
432
|
+
end
|
|
433
|
+
|
|
434
|
+
# Delete a Volume Disk
|
|
435
|
+
# Deletes a Volume Disk identified by {extId} in the Volume Group identified by {volumeGroupExtId}.
|
|
436
|
+
# @param volume_group_ext_id [String] The external identifier of a Volume Group.
|
|
437
|
+
# @param ext_id [String] The external identifier of a Volume Disk.
|
|
438
|
+
# @param ntnx_request_id [String] A unique identifier that is associated with each request. The provided value must be opaque and preferably in Universal Unique Identifier (UUID) format. This identifier is also used as an idempotence token for safely retrying requests in case of network errors. All the supported Nutanix API clients add this auto-generated request identifier to each request.
|
|
439
|
+
# @param [Hash] opts the optional parameters
|
|
440
|
+
# @return [DeleteVolumeDiskById202Response]
|
|
441
|
+
def delete_volume_disk_by_id(volume_group_ext_id, ext_id, ntnx_request_id, opts = {})
|
|
442
|
+
data, _status_code, _headers = delete_volume_disk_by_id_with_http_info(volume_group_ext_id, ext_id, ntnx_request_id, opts)
|
|
443
|
+
data
|
|
444
|
+
end
|
|
445
|
+
|
|
446
|
+
# Delete a Volume Disk
|
|
447
|
+
# Deletes a Volume Disk identified by {extId} in the Volume Group identified by {volumeGroupExtId}.
|
|
448
|
+
# @param volume_group_ext_id [String] The external identifier of a Volume Group.
|
|
449
|
+
# @param ext_id [String] The external identifier of a Volume Disk.
|
|
450
|
+
# @param ntnx_request_id [String] A unique identifier that is associated with each request. The provided value must be opaque and preferably in Universal Unique Identifier (UUID) format. This identifier is also used as an idempotence token for safely retrying requests in case of network errors. All the supported Nutanix API clients add this auto-generated request identifier to each request.
|
|
451
|
+
# @param [Hash] opts the optional parameters
|
|
452
|
+
# @return [Array<(DeleteVolumeDiskById202Response, Integer, Hash)>] DeleteVolumeDiskById202Response data, response status code and response headers
|
|
453
|
+
def delete_volume_disk_by_id_with_http_info(volume_group_ext_id, ext_id, ntnx_request_id, opts = {})
|
|
454
|
+
if @api_client.config.debugging
|
|
455
|
+
@api_client.config.logger.debug 'Calling API: VolumeGroupsApi.delete_volume_disk_by_id ...'
|
|
456
|
+
end
|
|
457
|
+
# verify the required parameter 'volume_group_ext_id' is set
|
|
458
|
+
if @api_client.config.client_side_validation && volume_group_ext_id.nil?
|
|
459
|
+
fail ArgumentError, "Missing the required parameter 'volume_group_ext_id' when calling VolumeGroupsApi.delete_volume_disk_by_id"
|
|
460
|
+
end
|
|
461
|
+
pattern = Regexp.new(/^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$/)
|
|
462
|
+
if @api_client.config.client_side_validation && volume_group_ext_id !~ pattern
|
|
463
|
+
fail ArgumentError, "invalid value for 'volume_group_ext_id' when calling VolumeGroupsApi.delete_volume_disk_by_id, must conform to the pattern #{pattern}."
|
|
464
|
+
end
|
|
465
|
+
|
|
466
|
+
# verify the required parameter 'ext_id' is set
|
|
467
|
+
if @api_client.config.client_side_validation && ext_id.nil?
|
|
468
|
+
fail ArgumentError, "Missing the required parameter 'ext_id' when calling VolumeGroupsApi.delete_volume_disk_by_id"
|
|
469
|
+
end
|
|
470
|
+
pattern = Regexp.new(/^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$/)
|
|
471
|
+
if @api_client.config.client_side_validation && ext_id !~ pattern
|
|
472
|
+
fail ArgumentError, "invalid value for 'ext_id' when calling VolumeGroupsApi.delete_volume_disk_by_id, must conform to the pattern #{pattern}."
|
|
473
|
+
end
|
|
474
|
+
|
|
475
|
+
# verify the required parameter 'ntnx_request_id' is set
|
|
476
|
+
if @api_client.config.client_side_validation && ntnx_request_id.nil?
|
|
477
|
+
fail ArgumentError, "Missing the required parameter 'ntnx_request_id' when calling VolumeGroupsApi.delete_volume_disk_by_id"
|
|
478
|
+
end
|
|
479
|
+
# resource path
|
|
480
|
+
local_var_path = '/volumes/v4.0/config/volume-groups/{volumeGroupExtId}/disks/{extId}'.sub('{' + 'volumeGroupExtId' + '}', CGI.escape(volume_group_ext_id.to_s)).sub('{' + 'extId' + '}', CGI.escape(ext_id.to_s))
|
|
481
|
+
|
|
482
|
+
# query parameters
|
|
483
|
+
query_params = opts[:query_params] || {}
|
|
484
|
+
|
|
485
|
+
# header parameters
|
|
486
|
+
header_params = opts[:header_params] || {}
|
|
487
|
+
# HTTP header 'Accept' (if needed)
|
|
488
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
489
|
+
header_params[:'NTNX-Request-Id'] = ntnx_request_id
|
|
490
|
+
|
|
491
|
+
# form parameters
|
|
492
|
+
form_params = opts[:form_params] || {}
|
|
493
|
+
|
|
494
|
+
# http body (model)
|
|
495
|
+
post_body = opts[:debug_body]
|
|
496
|
+
|
|
497
|
+
# return_type
|
|
498
|
+
return_type = opts[:debug_return_type] || 'DeleteVolumeDiskById202Response'
|
|
499
|
+
|
|
500
|
+
# auth_names
|
|
501
|
+
auth_names = opts[:debug_auth_names] || ['apiKeyAuthScheme', 'basicAuthScheme']
|
|
502
|
+
|
|
503
|
+
new_options = opts.merge(
|
|
504
|
+
:operation => :"VolumeGroupsApi.delete_volume_disk_by_id",
|
|
505
|
+
:header_params => header_params,
|
|
506
|
+
:query_params => query_params,
|
|
507
|
+
:form_params => form_params,
|
|
508
|
+
:body => post_body,
|
|
509
|
+
:auth_names => auth_names,
|
|
510
|
+
:return_type => return_type
|
|
511
|
+
)
|
|
512
|
+
|
|
513
|
+
data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
|
|
514
|
+
if @api_client.config.debugging
|
|
515
|
+
@api_client.config.logger.debug "API called: VolumeGroupsApi#delete_volume_disk_by_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
516
|
+
end
|
|
517
|
+
return data, status_code, headers
|
|
518
|
+
end
|
|
519
|
+
|
|
520
|
+
# Delete the Volume Group
|
|
521
|
+
# Delete the Volume Group identified by {extId}.
|
|
522
|
+
# @param ext_id [String] The external identifier of a Volume Group.
|
|
523
|
+
# @param ntnx_request_id [String] A unique identifier that is associated with each request. The provided value must be opaque and preferably in Universal Unique Identifier (UUID) format. This identifier is also used as an idempotence token for safely retrying requests in case of network errors. All the supported Nutanix API clients add this auto-generated request identifier to each request.
|
|
524
|
+
# @param [Hash] opts the optional parameters
|
|
525
|
+
# @return [DeleteVolumeGroupById202Response]
|
|
526
|
+
def delete_volume_group_by_id(ext_id, ntnx_request_id, opts = {})
|
|
527
|
+
data, _status_code, _headers = delete_volume_group_by_id_with_http_info(ext_id, ntnx_request_id, opts)
|
|
528
|
+
data
|
|
529
|
+
end
|
|
530
|
+
|
|
531
|
+
# Delete the Volume Group
|
|
532
|
+
# Delete the Volume Group identified by {extId}.
|
|
533
|
+
# @param ext_id [String] The external identifier of a Volume Group.
|
|
534
|
+
# @param ntnx_request_id [String] A unique identifier that is associated with each request. The provided value must be opaque and preferably in Universal Unique Identifier (UUID) format. This identifier is also used as an idempotence token for safely retrying requests in case of network errors. All the supported Nutanix API clients add this auto-generated request identifier to each request.
|
|
535
|
+
# @param [Hash] opts the optional parameters
|
|
536
|
+
# @return [Array<(DeleteVolumeGroupById202Response, Integer, Hash)>] DeleteVolumeGroupById202Response data, response status code and response headers
|
|
537
|
+
def delete_volume_group_by_id_with_http_info(ext_id, ntnx_request_id, opts = {})
|
|
538
|
+
if @api_client.config.debugging
|
|
539
|
+
@api_client.config.logger.debug 'Calling API: VolumeGroupsApi.delete_volume_group_by_id ...'
|
|
540
|
+
end
|
|
541
|
+
# verify the required parameter 'ext_id' is set
|
|
542
|
+
if @api_client.config.client_side_validation && ext_id.nil?
|
|
543
|
+
fail ArgumentError, "Missing the required parameter 'ext_id' when calling VolumeGroupsApi.delete_volume_group_by_id"
|
|
544
|
+
end
|
|
545
|
+
pattern = Regexp.new(/^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$/)
|
|
546
|
+
if @api_client.config.client_side_validation && ext_id !~ pattern
|
|
547
|
+
fail ArgumentError, "invalid value for 'ext_id' when calling VolumeGroupsApi.delete_volume_group_by_id, must conform to the pattern #{pattern}."
|
|
548
|
+
end
|
|
549
|
+
|
|
550
|
+
# verify the required parameter 'ntnx_request_id' is set
|
|
551
|
+
if @api_client.config.client_side_validation && ntnx_request_id.nil?
|
|
552
|
+
fail ArgumentError, "Missing the required parameter 'ntnx_request_id' when calling VolumeGroupsApi.delete_volume_group_by_id"
|
|
553
|
+
end
|
|
554
|
+
# resource path
|
|
555
|
+
local_var_path = '/volumes/v4.0/config/volume-groups/{extId}'.sub('{' + 'extId' + '}', CGI.escape(ext_id.to_s))
|
|
556
|
+
|
|
557
|
+
# query parameters
|
|
558
|
+
query_params = opts[:query_params] || {}
|
|
559
|
+
|
|
560
|
+
# header parameters
|
|
561
|
+
header_params = opts[:header_params] || {}
|
|
562
|
+
# HTTP header 'Accept' (if needed)
|
|
563
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
564
|
+
header_params[:'NTNX-Request-Id'] = ntnx_request_id
|
|
565
|
+
|
|
566
|
+
# form parameters
|
|
567
|
+
form_params = opts[:form_params] || {}
|
|
568
|
+
|
|
569
|
+
# http body (model)
|
|
570
|
+
post_body = opts[:debug_body]
|
|
571
|
+
|
|
572
|
+
# return_type
|
|
573
|
+
return_type = opts[:debug_return_type] || 'DeleteVolumeGroupById202Response'
|
|
574
|
+
|
|
575
|
+
# auth_names
|
|
576
|
+
auth_names = opts[:debug_auth_names] || ['apiKeyAuthScheme', 'basicAuthScheme']
|
|
577
|
+
|
|
578
|
+
new_options = opts.merge(
|
|
579
|
+
:operation => :"VolumeGroupsApi.delete_volume_group_by_id",
|
|
580
|
+
:header_params => header_params,
|
|
581
|
+
:query_params => query_params,
|
|
582
|
+
:form_params => form_params,
|
|
583
|
+
:body => post_body,
|
|
584
|
+
:auth_names => auth_names,
|
|
585
|
+
:return_type => return_type
|
|
586
|
+
)
|
|
587
|
+
|
|
588
|
+
data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
|
|
589
|
+
if @api_client.config.debugging
|
|
590
|
+
@api_client.config.logger.debug "API called: VolumeGroupsApi#delete_volume_group_by_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
591
|
+
end
|
|
592
|
+
return data, status_code, headers
|
|
593
|
+
end
|
|
594
|
+
|
|
595
|
+
# Detach an iSCSi client from the given Volume Group
|
|
596
|
+
# Detaches iSCSI initiator identified by {extId} from a Volume Group identified by {volumeGroupExtId}.
|
|
597
|
+
# @param ext_id [String] The external identifier of a Volume Group.
|
|
598
|
+
# @param ntnx_request_id [String] A unique identifier that is associated with each request. The provided value must be opaque and preferably in Universal Unique Identifier (UUID) format. This identifier is also used as an idempotence token for safely retrying requests in case of network errors. All the supported Nutanix API clients add this auto-generated request identifier to each request.
|
|
599
|
+
# @param volumes_v40_config_iscsi_client_attachment [VolumesV40ConfigIscsiClientAttachment] A model that represents an iSCSI client that can be associated with a Volume Group as an external attachment. It contains the minimal properties required for the attachment.
|
|
600
|
+
# @param [Hash] opts the optional parameters
|
|
601
|
+
# @return [DetachIscsiClient202Response]
|
|
602
|
+
def detach_iscsi_client(ext_id, ntnx_request_id, volumes_v40_config_iscsi_client_attachment, opts = {})
|
|
603
|
+
data, _status_code, _headers = detach_iscsi_client_with_http_info(ext_id, ntnx_request_id, volumes_v40_config_iscsi_client_attachment, opts)
|
|
604
|
+
data
|
|
605
|
+
end
|
|
606
|
+
|
|
607
|
+
# Detach an iSCSi client from the given Volume Group
|
|
608
|
+
# Detaches iSCSI initiator identified by {extId} from a Volume Group identified by {volumeGroupExtId}.
|
|
609
|
+
# @param ext_id [String] The external identifier of a Volume Group.
|
|
610
|
+
# @param ntnx_request_id [String] A unique identifier that is associated with each request. The provided value must be opaque and preferably in Universal Unique Identifier (UUID) format. This identifier is also used as an idempotence token for safely retrying requests in case of network errors. All the supported Nutanix API clients add this auto-generated request identifier to each request.
|
|
611
|
+
# @param volumes_v40_config_iscsi_client_attachment [VolumesV40ConfigIscsiClientAttachment] A model that represents an iSCSI client that can be associated with a Volume Group as an external attachment. It contains the minimal properties required for the attachment.
|
|
612
|
+
# @param [Hash] opts the optional parameters
|
|
613
|
+
# @return [Array<(DetachIscsiClient202Response, Integer, Hash)>] DetachIscsiClient202Response data, response status code and response headers
|
|
614
|
+
def detach_iscsi_client_with_http_info(ext_id, ntnx_request_id, volumes_v40_config_iscsi_client_attachment, opts = {})
|
|
615
|
+
if @api_client.config.debugging
|
|
616
|
+
@api_client.config.logger.debug 'Calling API: VolumeGroupsApi.detach_iscsi_client ...'
|
|
617
|
+
end
|
|
618
|
+
# verify the required parameter 'ext_id' is set
|
|
619
|
+
if @api_client.config.client_side_validation && ext_id.nil?
|
|
620
|
+
fail ArgumentError, "Missing the required parameter 'ext_id' when calling VolumeGroupsApi.detach_iscsi_client"
|
|
621
|
+
end
|
|
622
|
+
pattern = Regexp.new(/^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$/)
|
|
623
|
+
if @api_client.config.client_side_validation && ext_id !~ pattern
|
|
624
|
+
fail ArgumentError, "invalid value for 'ext_id' when calling VolumeGroupsApi.detach_iscsi_client, must conform to the pattern #{pattern}."
|
|
625
|
+
end
|
|
626
|
+
|
|
627
|
+
# verify the required parameter 'ntnx_request_id' is set
|
|
628
|
+
if @api_client.config.client_side_validation && ntnx_request_id.nil?
|
|
629
|
+
fail ArgumentError, "Missing the required parameter 'ntnx_request_id' when calling VolumeGroupsApi.detach_iscsi_client"
|
|
630
|
+
end
|
|
631
|
+
# verify the required parameter 'volumes_v40_config_iscsi_client_attachment' is set
|
|
632
|
+
if @api_client.config.client_side_validation && volumes_v40_config_iscsi_client_attachment.nil?
|
|
633
|
+
fail ArgumentError, "Missing the required parameter 'volumes_v40_config_iscsi_client_attachment' when calling VolumeGroupsApi.detach_iscsi_client"
|
|
634
|
+
end
|
|
635
|
+
# resource path
|
|
636
|
+
local_var_path = '/volumes/v4.0/config/volume-groups/{extId}/$actions/detach-iscsi-client'.sub('{' + 'extId' + '}', CGI.escape(ext_id.to_s))
|
|
637
|
+
|
|
638
|
+
# query parameters
|
|
639
|
+
query_params = opts[:query_params] || {}
|
|
640
|
+
|
|
641
|
+
# header parameters
|
|
642
|
+
header_params = opts[:header_params] || {}
|
|
643
|
+
# HTTP header 'Accept' (if needed)
|
|
644
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
645
|
+
# HTTP header 'Content-Type'
|
|
646
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
|
647
|
+
if !content_type.nil?
|
|
648
|
+
header_params['Content-Type'] = content_type
|
|
649
|
+
end
|
|
650
|
+
header_params[:'NTNX-Request-Id'] = ntnx_request_id
|
|
651
|
+
|
|
652
|
+
# form parameters
|
|
653
|
+
form_params = opts[:form_params] || {}
|
|
654
|
+
|
|
655
|
+
# http body (model)
|
|
656
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(volumes_v40_config_iscsi_client_attachment)
|
|
657
|
+
|
|
658
|
+
# return_type
|
|
659
|
+
return_type = opts[:debug_return_type] || 'DetachIscsiClient202Response'
|
|
660
|
+
|
|
661
|
+
# auth_names
|
|
662
|
+
auth_names = opts[:debug_auth_names] || ['apiKeyAuthScheme', 'basicAuthScheme']
|
|
663
|
+
|
|
664
|
+
new_options = opts.merge(
|
|
665
|
+
:operation => :"VolumeGroupsApi.detach_iscsi_client",
|
|
666
|
+
:header_params => header_params,
|
|
667
|
+
:query_params => query_params,
|
|
668
|
+
:form_params => form_params,
|
|
669
|
+
:body => post_body,
|
|
670
|
+
:auth_names => auth_names,
|
|
671
|
+
:return_type => return_type
|
|
672
|
+
)
|
|
673
|
+
|
|
674
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
|
675
|
+
if @api_client.config.debugging
|
|
676
|
+
@api_client.config.logger.debug "API called: VolumeGroupsApi#detach_iscsi_client\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
677
|
+
end
|
|
678
|
+
return data, status_code, headers
|
|
679
|
+
end
|
|
680
|
+
|
|
681
|
+
# Detach an AHV VM from the given Volume Group
|
|
682
|
+
# Detaches VM identified by {extId} from a Volume Group identified by {volumeGroupExtId}.
|
|
683
|
+
# @param ext_id [String] The external identifier of a Volume Group.
|
|
684
|
+
# @param ntnx_request_id [String] A unique identifier that is associated with each request. The provided value must be opaque and preferably in Universal Unique Identifier (UUID) format. This identifier is also used as an idempotence token for safely retrying requests in case of network errors. All the supported Nutanix API clients add this auto-generated request identifier to each request.
|
|
685
|
+
# @param volumes_v40_config_vm_attachment [VolumesV40ConfigVmAttachment] A model that represents a VM reference that can be associated with a Volume Group as an AHV hypervisor attachment.
|
|
686
|
+
# @param [Hash] opts the optional parameters
|
|
687
|
+
# @return [DetachVm202Response]
|
|
688
|
+
def detach_vm(ext_id, ntnx_request_id, volumes_v40_config_vm_attachment, opts = {})
|
|
689
|
+
data, _status_code, _headers = detach_vm_with_http_info(ext_id, ntnx_request_id, volumes_v40_config_vm_attachment, opts)
|
|
690
|
+
data
|
|
691
|
+
end
|
|
692
|
+
|
|
693
|
+
# Detach an AHV VM from the given Volume Group
|
|
694
|
+
# Detaches VM identified by {extId} from a Volume Group identified by {volumeGroupExtId}.
|
|
695
|
+
# @param ext_id [String] The external identifier of a Volume Group.
|
|
696
|
+
# @param ntnx_request_id [String] A unique identifier that is associated with each request. The provided value must be opaque and preferably in Universal Unique Identifier (UUID) format. This identifier is also used as an idempotence token for safely retrying requests in case of network errors. All the supported Nutanix API clients add this auto-generated request identifier to each request.
|
|
697
|
+
# @param volumes_v40_config_vm_attachment [VolumesV40ConfigVmAttachment] A model that represents a VM reference that can be associated with a Volume Group as an AHV hypervisor attachment.
|
|
698
|
+
# @param [Hash] opts the optional parameters
|
|
699
|
+
# @return [Array<(DetachVm202Response, Integer, Hash)>] DetachVm202Response data, response status code and response headers
|
|
700
|
+
def detach_vm_with_http_info(ext_id, ntnx_request_id, volumes_v40_config_vm_attachment, opts = {})
|
|
701
|
+
if @api_client.config.debugging
|
|
702
|
+
@api_client.config.logger.debug 'Calling API: VolumeGroupsApi.detach_vm ...'
|
|
703
|
+
end
|
|
704
|
+
# verify the required parameter 'ext_id' is set
|
|
705
|
+
if @api_client.config.client_side_validation && ext_id.nil?
|
|
706
|
+
fail ArgumentError, "Missing the required parameter 'ext_id' when calling VolumeGroupsApi.detach_vm"
|
|
707
|
+
end
|
|
708
|
+
pattern = Regexp.new(/^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$/)
|
|
709
|
+
if @api_client.config.client_side_validation && ext_id !~ pattern
|
|
710
|
+
fail ArgumentError, "invalid value for 'ext_id' when calling VolumeGroupsApi.detach_vm, must conform to the pattern #{pattern}."
|
|
711
|
+
end
|
|
712
|
+
|
|
713
|
+
# verify the required parameter 'ntnx_request_id' is set
|
|
714
|
+
if @api_client.config.client_side_validation && ntnx_request_id.nil?
|
|
715
|
+
fail ArgumentError, "Missing the required parameter 'ntnx_request_id' when calling VolumeGroupsApi.detach_vm"
|
|
716
|
+
end
|
|
717
|
+
# verify the required parameter 'volumes_v40_config_vm_attachment' is set
|
|
718
|
+
if @api_client.config.client_side_validation && volumes_v40_config_vm_attachment.nil?
|
|
719
|
+
fail ArgumentError, "Missing the required parameter 'volumes_v40_config_vm_attachment' when calling VolumeGroupsApi.detach_vm"
|
|
720
|
+
end
|
|
721
|
+
# resource path
|
|
722
|
+
local_var_path = '/volumes/v4.0/config/volume-groups/{extId}/$actions/detach-vm'.sub('{' + 'extId' + '}', CGI.escape(ext_id.to_s))
|
|
723
|
+
|
|
724
|
+
# query parameters
|
|
725
|
+
query_params = opts[:query_params] || {}
|
|
726
|
+
|
|
727
|
+
# header parameters
|
|
728
|
+
header_params = opts[:header_params] || {}
|
|
729
|
+
# HTTP header 'Accept' (if needed)
|
|
730
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
731
|
+
# HTTP header 'Content-Type'
|
|
732
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
|
733
|
+
if !content_type.nil?
|
|
734
|
+
header_params['Content-Type'] = content_type
|
|
735
|
+
end
|
|
736
|
+
header_params[:'NTNX-Request-Id'] = ntnx_request_id
|
|
737
|
+
|
|
738
|
+
# form parameters
|
|
739
|
+
form_params = opts[:form_params] || {}
|
|
740
|
+
|
|
741
|
+
# http body (model)
|
|
742
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(volumes_v40_config_vm_attachment)
|
|
743
|
+
|
|
744
|
+
# return_type
|
|
745
|
+
return_type = opts[:debug_return_type] || 'DetachVm202Response'
|
|
746
|
+
|
|
747
|
+
# auth_names
|
|
748
|
+
auth_names = opts[:debug_auth_names] || ['apiKeyAuthScheme', 'basicAuthScheme']
|
|
749
|
+
|
|
750
|
+
new_options = opts.merge(
|
|
751
|
+
:operation => :"VolumeGroupsApi.detach_vm",
|
|
752
|
+
:header_params => header_params,
|
|
753
|
+
:query_params => query_params,
|
|
754
|
+
:form_params => form_params,
|
|
755
|
+
:body => post_body,
|
|
756
|
+
:auth_names => auth_names,
|
|
757
|
+
:return_type => return_type
|
|
758
|
+
)
|
|
759
|
+
|
|
760
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
|
761
|
+
if @api_client.config.debugging
|
|
762
|
+
@api_client.config.logger.debug "API called: VolumeGroupsApi#detach_vm\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
763
|
+
end
|
|
764
|
+
return data, status_code, headers
|
|
765
|
+
end
|
|
766
|
+
|
|
767
|
+
# Disassociate category from a Volume Group
|
|
768
|
+
# Disassociates a category from a Volume Group identified by {extId}.
|
|
769
|
+
# @param ext_id [String] The external identifier of a Volume Group.
|
|
770
|
+
# @param volumes_v40_config_category_entity_references [VolumesV40ConfigCategoryEntityReferences] The list of categories to be associated/disassociated with the Volume Group. This is a mandatory field.
|
|
771
|
+
# @param [Hash] opts the optional parameters
|
|
772
|
+
# @return [DisassociateCategory202Response]
|
|
773
|
+
def disassociate_category(ext_id, volumes_v40_config_category_entity_references, opts = {})
|
|
774
|
+
data, _status_code, _headers = disassociate_category_with_http_info(ext_id, volumes_v40_config_category_entity_references, opts)
|
|
775
|
+
data
|
|
776
|
+
end
|
|
777
|
+
|
|
778
|
+
# Disassociate category from a Volume Group
|
|
779
|
+
# Disassociates a category from a Volume Group identified by {extId}.
|
|
780
|
+
# @param ext_id [String] The external identifier of a Volume Group.
|
|
781
|
+
# @param volumes_v40_config_category_entity_references [VolumesV40ConfigCategoryEntityReferences] The list of categories to be associated/disassociated with the Volume Group. This is a mandatory field.
|
|
782
|
+
# @param [Hash] opts the optional parameters
|
|
783
|
+
# @return [Array<(DisassociateCategory202Response, Integer, Hash)>] DisassociateCategory202Response data, response status code and response headers
|
|
784
|
+
def disassociate_category_with_http_info(ext_id, volumes_v40_config_category_entity_references, opts = {})
|
|
785
|
+
if @api_client.config.debugging
|
|
786
|
+
@api_client.config.logger.debug 'Calling API: VolumeGroupsApi.disassociate_category ...'
|
|
787
|
+
end
|
|
788
|
+
# verify the required parameter 'ext_id' is set
|
|
789
|
+
if @api_client.config.client_side_validation && ext_id.nil?
|
|
790
|
+
fail ArgumentError, "Missing the required parameter 'ext_id' when calling VolumeGroupsApi.disassociate_category"
|
|
791
|
+
end
|
|
792
|
+
pattern = Regexp.new(/^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$/)
|
|
793
|
+
if @api_client.config.client_side_validation && ext_id !~ pattern
|
|
794
|
+
fail ArgumentError, "invalid value for 'ext_id' when calling VolumeGroupsApi.disassociate_category, must conform to the pattern #{pattern}."
|
|
795
|
+
end
|
|
796
|
+
|
|
797
|
+
# verify the required parameter 'volumes_v40_config_category_entity_references' is set
|
|
798
|
+
if @api_client.config.client_side_validation && volumes_v40_config_category_entity_references.nil?
|
|
799
|
+
fail ArgumentError, "Missing the required parameter 'volumes_v40_config_category_entity_references' when calling VolumeGroupsApi.disassociate_category"
|
|
800
|
+
end
|
|
801
|
+
# resource path
|
|
802
|
+
local_var_path = '/volumes/v4.0/config/volume-groups/{extId}/$actions/disassociate-category'.sub('{' + 'extId' + '}', CGI.escape(ext_id.to_s))
|
|
803
|
+
|
|
804
|
+
# query parameters
|
|
805
|
+
query_params = opts[:query_params] || {}
|
|
806
|
+
|
|
807
|
+
# header parameters
|
|
808
|
+
header_params = opts[:header_params] || {}
|
|
809
|
+
# HTTP header 'Accept' (if needed)
|
|
810
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
811
|
+
# HTTP header 'Content-Type'
|
|
812
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
|
813
|
+
if !content_type.nil?
|
|
814
|
+
header_params['Content-Type'] = content_type
|
|
815
|
+
end
|
|
816
|
+
|
|
817
|
+
# form parameters
|
|
818
|
+
form_params = opts[:form_params] || {}
|
|
819
|
+
|
|
820
|
+
# http body (model)
|
|
821
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(volumes_v40_config_category_entity_references)
|
|
822
|
+
|
|
823
|
+
# return_type
|
|
824
|
+
return_type = opts[:debug_return_type] || 'DisassociateCategory202Response'
|
|
825
|
+
|
|
826
|
+
# auth_names
|
|
827
|
+
auth_names = opts[:debug_auth_names] || ['apiKeyAuthScheme', 'basicAuthScheme']
|
|
828
|
+
|
|
829
|
+
new_options = opts.merge(
|
|
830
|
+
:operation => :"VolumeGroupsApi.disassociate_category",
|
|
831
|
+
:header_params => header_params,
|
|
832
|
+
:query_params => query_params,
|
|
833
|
+
:form_params => form_params,
|
|
834
|
+
:body => post_body,
|
|
835
|
+
:auth_names => auth_names,
|
|
836
|
+
:return_type => return_type
|
|
837
|
+
)
|
|
838
|
+
|
|
839
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
|
840
|
+
if @api_client.config.debugging
|
|
841
|
+
@api_client.config.logger.debug "API called: VolumeGroupsApi#disassociate_category\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
842
|
+
end
|
|
843
|
+
return data, status_code, headers
|
|
844
|
+
end
|
|
845
|
+
|
|
846
|
+
# Get the details of a Volume Disk
|
|
847
|
+
# Query the Volume Disk identified by {extId} in the Volume Group identified by {volumeGroupExtId}.
|
|
848
|
+
# @param volume_group_ext_id [String] The external identifier of a Volume Group.
|
|
849
|
+
# @param ext_id [String] The external identifier of a Volume Disk.
|
|
850
|
+
# @param [Hash] opts the optional parameters
|
|
851
|
+
# @return [GetVolumeDiskById200Response]
|
|
852
|
+
def get_volume_disk_by_id(volume_group_ext_id, ext_id, opts = {})
|
|
853
|
+
data, _status_code, _headers = get_volume_disk_by_id_with_http_info(volume_group_ext_id, ext_id, opts)
|
|
854
|
+
data
|
|
855
|
+
end
|
|
856
|
+
|
|
857
|
+
# Get the details of a Volume Disk
|
|
858
|
+
# Query the Volume Disk identified by {extId} in the Volume Group identified by {volumeGroupExtId}.
|
|
859
|
+
# @param volume_group_ext_id [String] The external identifier of a Volume Group.
|
|
860
|
+
# @param ext_id [String] The external identifier of a Volume Disk.
|
|
861
|
+
# @param [Hash] opts the optional parameters
|
|
862
|
+
# @return [Array<(GetVolumeDiskById200Response, Integer, Hash)>] GetVolumeDiskById200Response data, response status code and response headers
|
|
863
|
+
def get_volume_disk_by_id_with_http_info(volume_group_ext_id, ext_id, opts = {})
|
|
864
|
+
if @api_client.config.debugging
|
|
865
|
+
@api_client.config.logger.debug 'Calling API: VolumeGroupsApi.get_volume_disk_by_id ...'
|
|
866
|
+
end
|
|
867
|
+
# verify the required parameter 'volume_group_ext_id' is set
|
|
868
|
+
if @api_client.config.client_side_validation && volume_group_ext_id.nil?
|
|
869
|
+
fail ArgumentError, "Missing the required parameter 'volume_group_ext_id' when calling VolumeGroupsApi.get_volume_disk_by_id"
|
|
870
|
+
end
|
|
871
|
+
pattern = Regexp.new(/^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$/)
|
|
872
|
+
if @api_client.config.client_side_validation && volume_group_ext_id !~ pattern
|
|
873
|
+
fail ArgumentError, "invalid value for 'volume_group_ext_id' when calling VolumeGroupsApi.get_volume_disk_by_id, must conform to the pattern #{pattern}."
|
|
874
|
+
end
|
|
875
|
+
|
|
876
|
+
# verify the required parameter 'ext_id' is set
|
|
877
|
+
if @api_client.config.client_side_validation && ext_id.nil?
|
|
878
|
+
fail ArgumentError, "Missing the required parameter 'ext_id' when calling VolumeGroupsApi.get_volume_disk_by_id"
|
|
879
|
+
end
|
|
880
|
+
pattern = Regexp.new(/^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$/)
|
|
881
|
+
if @api_client.config.client_side_validation && ext_id !~ pattern
|
|
882
|
+
fail ArgumentError, "invalid value for 'ext_id' when calling VolumeGroupsApi.get_volume_disk_by_id, must conform to the pattern #{pattern}."
|
|
883
|
+
end
|
|
884
|
+
|
|
885
|
+
# resource path
|
|
886
|
+
local_var_path = '/volumes/v4.0/config/volume-groups/{volumeGroupExtId}/disks/{extId}'.sub('{' + 'volumeGroupExtId' + '}', CGI.escape(volume_group_ext_id.to_s)).sub('{' + 'extId' + '}', CGI.escape(ext_id.to_s))
|
|
887
|
+
|
|
888
|
+
# query parameters
|
|
889
|
+
query_params = opts[:query_params] || {}
|
|
890
|
+
|
|
891
|
+
# header parameters
|
|
892
|
+
header_params = opts[:header_params] || {}
|
|
893
|
+
# HTTP header 'Accept' (if needed)
|
|
894
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
895
|
+
|
|
896
|
+
# form parameters
|
|
897
|
+
form_params = opts[:form_params] || {}
|
|
898
|
+
|
|
899
|
+
# http body (model)
|
|
900
|
+
post_body = opts[:debug_body]
|
|
901
|
+
|
|
902
|
+
# return_type
|
|
903
|
+
return_type = opts[:debug_return_type] || 'GetVolumeDiskById200Response'
|
|
904
|
+
|
|
905
|
+
# auth_names
|
|
906
|
+
auth_names = opts[:debug_auth_names] || ['apiKeyAuthScheme', 'basicAuthScheme']
|
|
907
|
+
|
|
908
|
+
new_options = opts.merge(
|
|
909
|
+
:operation => :"VolumeGroupsApi.get_volume_disk_by_id",
|
|
910
|
+
:header_params => header_params,
|
|
911
|
+
:query_params => query_params,
|
|
912
|
+
:form_params => form_params,
|
|
913
|
+
:body => post_body,
|
|
914
|
+
:auth_names => auth_names,
|
|
915
|
+
:return_type => return_type
|
|
916
|
+
)
|
|
917
|
+
|
|
918
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
919
|
+
if @api_client.config.debugging
|
|
920
|
+
@api_client.config.logger.debug "API called: VolumeGroupsApi#get_volume_disk_by_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
921
|
+
end
|
|
922
|
+
return data, status_code, headers
|
|
923
|
+
end
|
|
924
|
+
|
|
925
|
+
# Get statistics for a Volume Disk
|
|
926
|
+
# Query the Volume Disk stats identified by {diskExtId}.
|
|
927
|
+
# @param volume_group_ext_id [String] The external identifier of a Volume Group.
|
|
928
|
+
# @param ext_id [String] The external identifier of a Volume Disk.
|
|
929
|
+
# @param start_time [Time] The start time of the period for which stats should be reported. The value should be in extended ISO-8601 format. For example, start time of 2022-04-23T01:23:45.678+09:00 would consider all stats starting at 1:23:45.678 on the 23rd of April 2022. Details around ISO-8601 format can be found at https://www.iso.org/standard/70907.html
|
|
930
|
+
# @param end_time [Time] The end time of the period for which stats should be reported. The value should be in extended ISO-8601 format. For example, end time of 2022-04-23T013:23:45.678+09:00 would consider all stats till 13:23:45 .678 on the 23rd of April 2022. Details around ISO-8601 format can be found at https://www.iso.org/standard/70907.html
|
|
931
|
+
# @param [Hash] opts the optional parameters
|
|
932
|
+
# @option opts [Integer] :sampling_interval The sampling interval in seconds at which statistical data should be collected. For example, if you want performance statistics every 30 seconds, then provide the value as 30.
|
|
933
|
+
# @option opts [CommonV10StatsDownSamplingOperator] :stat_type
|
|
934
|
+
# @option opts [String] :select A URL query parameter that allows clients to request a specific set of properties for each entity or complex type. Expression specified with the $select must conform to the [OData V4.01](https://docs.oasis-open.org/odata/odata/v4.01/odata-v4.01-part1-protocol.html) URL conventions. If a $select expression consists of a single select item that is an asterisk (i.e., *), then all properties on the matching resource will be returned. - controllerAvgIOLatencyUsecs - controllerAvgReadIOLatencyUsecs - controllerAvgWriteIOLatencyUsecs - controllerIOBandwidthKBps - controllerNumIOPS - controllerNumReadIOPS - controllerNumWriteIOPS - controllerReadIOBandwidthKBps - controllerUserBytes - controllerWriteIOBandwidthKBps
|
|
935
|
+
# @return [GetVolumeDiskStats200Response]
|
|
936
|
+
def get_volume_disk_stats(volume_group_ext_id, ext_id, start_time, end_time, opts = {})
|
|
937
|
+
data, _status_code, _headers = get_volume_disk_stats_with_http_info(volume_group_ext_id, ext_id, start_time, end_time, opts)
|
|
938
|
+
data
|
|
939
|
+
end
|
|
940
|
+
|
|
941
|
+
# Get statistics for a Volume Disk
|
|
942
|
+
# Query the Volume Disk stats identified by {diskExtId}.
|
|
943
|
+
# @param volume_group_ext_id [String] The external identifier of a Volume Group.
|
|
944
|
+
# @param ext_id [String] The external identifier of a Volume Disk.
|
|
945
|
+
# @param start_time [Time] The start time of the period for which stats should be reported. The value should be in extended ISO-8601 format. For example, start time of 2022-04-23T01:23:45.678+09:00 would consider all stats starting at 1:23:45.678 on the 23rd of April 2022. Details around ISO-8601 format can be found at https://www.iso.org/standard/70907.html
|
|
946
|
+
# @param end_time [Time] The end time of the period for which stats should be reported. The value should be in extended ISO-8601 format. For example, end time of 2022-04-23T013:23:45.678+09:00 would consider all stats till 13:23:45 .678 on the 23rd of April 2022. Details around ISO-8601 format can be found at https://www.iso.org/standard/70907.html
|
|
947
|
+
# @param [Hash] opts the optional parameters
|
|
948
|
+
# @option opts [Integer] :sampling_interval The sampling interval in seconds at which statistical data should be collected. For example, if you want performance statistics every 30 seconds, then provide the value as 30.
|
|
949
|
+
# @option opts [CommonV10StatsDownSamplingOperator] :stat_type
|
|
950
|
+
# @option opts [String] :select A URL query parameter that allows clients to request a specific set of properties for each entity or complex type. Expression specified with the $select must conform to the [OData V4.01](https://docs.oasis-open.org/odata/odata/v4.01/odata-v4.01-part1-protocol.html) URL conventions. If a $select expression consists of a single select item that is an asterisk (i.e., *), then all properties on the matching resource will be returned. - controllerAvgIOLatencyUsecs - controllerAvgReadIOLatencyUsecs - controllerAvgWriteIOLatencyUsecs - controllerIOBandwidthKBps - controllerNumIOPS - controllerNumReadIOPS - controllerNumWriteIOPS - controllerReadIOBandwidthKBps - controllerUserBytes - controllerWriteIOBandwidthKBps
|
|
951
|
+
# @return [Array<(GetVolumeDiskStats200Response, Integer, Hash)>] GetVolumeDiskStats200Response data, response status code and response headers
|
|
952
|
+
def get_volume_disk_stats_with_http_info(volume_group_ext_id, ext_id, start_time, end_time, opts = {})
|
|
953
|
+
if @api_client.config.debugging
|
|
954
|
+
@api_client.config.logger.debug 'Calling API: VolumeGroupsApi.get_volume_disk_stats ...'
|
|
955
|
+
end
|
|
956
|
+
# verify the required parameter 'volume_group_ext_id' is set
|
|
957
|
+
if @api_client.config.client_side_validation && volume_group_ext_id.nil?
|
|
958
|
+
fail ArgumentError, "Missing the required parameter 'volume_group_ext_id' when calling VolumeGroupsApi.get_volume_disk_stats"
|
|
959
|
+
end
|
|
960
|
+
pattern = Regexp.new(/^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$/)
|
|
961
|
+
if @api_client.config.client_side_validation && volume_group_ext_id !~ pattern
|
|
962
|
+
fail ArgumentError, "invalid value for 'volume_group_ext_id' when calling VolumeGroupsApi.get_volume_disk_stats, must conform to the pattern #{pattern}."
|
|
963
|
+
end
|
|
964
|
+
|
|
965
|
+
# verify the required parameter 'ext_id' is set
|
|
966
|
+
if @api_client.config.client_side_validation && ext_id.nil?
|
|
967
|
+
fail ArgumentError, "Missing the required parameter 'ext_id' when calling VolumeGroupsApi.get_volume_disk_stats"
|
|
968
|
+
end
|
|
969
|
+
pattern = Regexp.new(/^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$/)
|
|
970
|
+
if @api_client.config.client_side_validation && ext_id !~ pattern
|
|
971
|
+
fail ArgumentError, "invalid value for 'ext_id' when calling VolumeGroupsApi.get_volume_disk_stats, must conform to the pattern #{pattern}."
|
|
972
|
+
end
|
|
973
|
+
|
|
974
|
+
# verify the required parameter 'start_time' is set
|
|
975
|
+
if @api_client.config.client_side_validation && start_time.nil?
|
|
976
|
+
fail ArgumentError, "Missing the required parameter 'start_time' when calling VolumeGroupsApi.get_volume_disk_stats"
|
|
977
|
+
end
|
|
978
|
+
# verify the required parameter 'end_time' is set
|
|
979
|
+
if @api_client.config.client_side_validation && end_time.nil?
|
|
980
|
+
fail ArgumentError, "Missing the required parameter 'end_time' when calling VolumeGroupsApi.get_volume_disk_stats"
|
|
981
|
+
end
|
|
982
|
+
if @api_client.config.client_side_validation && !opts[:'sampling_interval'].nil? && opts[:'sampling_interval'] < 1
|
|
983
|
+
fail ArgumentError, 'invalid value for "opts[:"sampling_interval"]" when calling VolumeGroupsApi.get_volume_disk_stats, must be greater than or equal to 1.'
|
|
984
|
+
end
|
|
985
|
+
|
|
986
|
+
# resource path
|
|
987
|
+
local_var_path = '/volumes/v4.0/stats/volume-groups/{volumeGroupExtId}/disks/{extId}'.sub('{' + 'volumeGroupExtId' + '}', CGI.escape(volume_group_ext_id.to_s)).sub('{' + 'extId' + '}', CGI.escape(ext_id.to_s))
|
|
988
|
+
|
|
989
|
+
# query parameters
|
|
990
|
+
query_params = opts[:query_params] || {}
|
|
991
|
+
query_params[:'$startTime'] = start_time
|
|
992
|
+
query_params[:'$endTime'] = end_time
|
|
993
|
+
query_params[:'$samplingInterval'] = opts[:'sampling_interval'] if !opts[:'sampling_interval'].nil?
|
|
994
|
+
query_params[:'$statType'] = opts[:'stat_type'] if !opts[:'stat_type'].nil?
|
|
995
|
+
query_params[:'$select'] = opts[:'select'] if !opts[:'select'].nil?
|
|
996
|
+
|
|
997
|
+
# header parameters
|
|
998
|
+
header_params = opts[:header_params] || {}
|
|
999
|
+
# HTTP header 'Accept' (if needed)
|
|
1000
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
1001
|
+
|
|
1002
|
+
# form parameters
|
|
1003
|
+
form_params = opts[:form_params] || {}
|
|
1004
|
+
|
|
1005
|
+
# http body (model)
|
|
1006
|
+
post_body = opts[:debug_body]
|
|
1007
|
+
|
|
1008
|
+
# return_type
|
|
1009
|
+
return_type = opts[:debug_return_type] || 'GetVolumeDiskStats200Response'
|
|
1010
|
+
|
|
1011
|
+
# auth_names
|
|
1012
|
+
auth_names = opts[:debug_auth_names] || ['apiKeyAuthScheme', 'basicAuthScheme']
|
|
1013
|
+
|
|
1014
|
+
new_options = opts.merge(
|
|
1015
|
+
:operation => :"VolumeGroupsApi.get_volume_disk_stats",
|
|
1016
|
+
:header_params => header_params,
|
|
1017
|
+
:query_params => query_params,
|
|
1018
|
+
:form_params => form_params,
|
|
1019
|
+
:body => post_body,
|
|
1020
|
+
:auth_names => auth_names,
|
|
1021
|
+
:return_type => return_type
|
|
1022
|
+
)
|
|
1023
|
+
|
|
1024
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
1025
|
+
if @api_client.config.debugging
|
|
1026
|
+
@api_client.config.logger.debug "API called: VolumeGroupsApi#get_volume_disk_stats\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
1027
|
+
end
|
|
1028
|
+
return data, status_code, headers
|
|
1029
|
+
end
|
|
1030
|
+
|
|
1031
|
+
# Get a Volume Group
|
|
1032
|
+
# Query the Volume Group identified by {extId}.
|
|
1033
|
+
# @param ext_id [String] The external identifier of a Volume Group.
|
|
1034
|
+
# @param [Hash] opts the optional parameters
|
|
1035
|
+
# @return [GetVolumeGroupById200Response]
|
|
1036
|
+
def get_volume_group_by_id(ext_id, opts = {})
|
|
1037
|
+
data, _status_code, _headers = get_volume_group_by_id_with_http_info(ext_id, opts)
|
|
1038
|
+
data
|
|
1039
|
+
end
|
|
1040
|
+
|
|
1041
|
+
# Get a Volume Group
|
|
1042
|
+
# Query the Volume Group identified by {extId}.
|
|
1043
|
+
# @param ext_id [String] The external identifier of a Volume Group.
|
|
1044
|
+
# @param [Hash] opts the optional parameters
|
|
1045
|
+
# @return [Array<(GetVolumeGroupById200Response, Integer, Hash)>] GetVolumeGroupById200Response data, response status code and response headers
|
|
1046
|
+
def get_volume_group_by_id_with_http_info(ext_id, opts = {})
|
|
1047
|
+
if @api_client.config.debugging
|
|
1048
|
+
@api_client.config.logger.debug 'Calling API: VolumeGroupsApi.get_volume_group_by_id ...'
|
|
1049
|
+
end
|
|
1050
|
+
# verify the required parameter 'ext_id' is set
|
|
1051
|
+
if @api_client.config.client_side_validation && ext_id.nil?
|
|
1052
|
+
fail ArgumentError, "Missing the required parameter 'ext_id' when calling VolumeGroupsApi.get_volume_group_by_id"
|
|
1053
|
+
end
|
|
1054
|
+
pattern = Regexp.new(/^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$/)
|
|
1055
|
+
if @api_client.config.client_side_validation && ext_id !~ pattern
|
|
1056
|
+
fail ArgumentError, "invalid value for 'ext_id' when calling VolumeGroupsApi.get_volume_group_by_id, must conform to the pattern #{pattern}."
|
|
1057
|
+
end
|
|
1058
|
+
|
|
1059
|
+
# resource path
|
|
1060
|
+
local_var_path = '/volumes/v4.0/config/volume-groups/{extId}'.sub('{' + 'extId' + '}', CGI.escape(ext_id.to_s))
|
|
1061
|
+
|
|
1062
|
+
# query parameters
|
|
1063
|
+
query_params = opts[:query_params] || {}
|
|
1064
|
+
|
|
1065
|
+
# header parameters
|
|
1066
|
+
header_params = opts[:header_params] || {}
|
|
1067
|
+
# HTTP header 'Accept' (if needed)
|
|
1068
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
1069
|
+
|
|
1070
|
+
# form parameters
|
|
1071
|
+
form_params = opts[:form_params] || {}
|
|
1072
|
+
|
|
1073
|
+
# http body (model)
|
|
1074
|
+
post_body = opts[:debug_body]
|
|
1075
|
+
|
|
1076
|
+
# return_type
|
|
1077
|
+
return_type = opts[:debug_return_type] || 'GetVolumeGroupById200Response'
|
|
1078
|
+
|
|
1079
|
+
# auth_names
|
|
1080
|
+
auth_names = opts[:debug_auth_names] || ['apiKeyAuthScheme', 'basicAuthScheme']
|
|
1081
|
+
|
|
1082
|
+
new_options = opts.merge(
|
|
1083
|
+
:operation => :"VolumeGroupsApi.get_volume_group_by_id",
|
|
1084
|
+
:header_params => header_params,
|
|
1085
|
+
:query_params => query_params,
|
|
1086
|
+
:form_params => form_params,
|
|
1087
|
+
:body => post_body,
|
|
1088
|
+
:auth_names => auth_names,
|
|
1089
|
+
:return_type => return_type
|
|
1090
|
+
)
|
|
1091
|
+
|
|
1092
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
1093
|
+
if @api_client.config.debugging
|
|
1094
|
+
@api_client.config.logger.debug "API called: VolumeGroupsApi#get_volume_group_by_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
1095
|
+
end
|
|
1096
|
+
return data, status_code, headers
|
|
1097
|
+
end
|
|
1098
|
+
|
|
1099
|
+
# Fetch metadata information associated with a Volume Group.
|
|
1100
|
+
# Query for metadata information which is associated with the Volume Group identified by {extId}.
|
|
1101
|
+
# @param volume_group_ext_id [String] The external identifier of a Volume Group.
|
|
1102
|
+
# @param [Hash] opts the optional parameters
|
|
1103
|
+
# @return [GetVolumeGroupMetadataById200Response]
|
|
1104
|
+
def get_volume_group_metadata_by_id(volume_group_ext_id, opts = {})
|
|
1105
|
+
data, _status_code, _headers = get_volume_group_metadata_by_id_with_http_info(volume_group_ext_id, opts)
|
|
1106
|
+
data
|
|
1107
|
+
end
|
|
1108
|
+
|
|
1109
|
+
# Fetch metadata information associated with a Volume Group.
|
|
1110
|
+
# Query for metadata information which is associated with the Volume Group identified by {extId}.
|
|
1111
|
+
# @param volume_group_ext_id [String] The external identifier of a Volume Group.
|
|
1112
|
+
# @param [Hash] opts the optional parameters
|
|
1113
|
+
# @return [Array<(GetVolumeGroupMetadataById200Response, Integer, Hash)>] GetVolumeGroupMetadataById200Response data, response status code and response headers
|
|
1114
|
+
def get_volume_group_metadata_by_id_with_http_info(volume_group_ext_id, opts = {})
|
|
1115
|
+
if @api_client.config.debugging
|
|
1116
|
+
@api_client.config.logger.debug 'Calling API: VolumeGroupsApi.get_volume_group_metadata_by_id ...'
|
|
1117
|
+
end
|
|
1118
|
+
# verify the required parameter 'volume_group_ext_id' is set
|
|
1119
|
+
if @api_client.config.client_side_validation && volume_group_ext_id.nil?
|
|
1120
|
+
fail ArgumentError, "Missing the required parameter 'volume_group_ext_id' when calling VolumeGroupsApi.get_volume_group_metadata_by_id"
|
|
1121
|
+
end
|
|
1122
|
+
pattern = Regexp.new(/^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$/)
|
|
1123
|
+
if @api_client.config.client_side_validation && volume_group_ext_id !~ pattern
|
|
1124
|
+
fail ArgumentError, "invalid value for 'volume_group_ext_id' when calling VolumeGroupsApi.get_volume_group_metadata_by_id, must conform to the pattern #{pattern}."
|
|
1125
|
+
end
|
|
1126
|
+
|
|
1127
|
+
# resource path
|
|
1128
|
+
local_var_path = '/volumes/v4.0/config/volume-groups/{volumeGroupExtId}/metadata'.sub('{' + 'volumeGroupExtId' + '}', CGI.escape(volume_group_ext_id.to_s))
|
|
1129
|
+
|
|
1130
|
+
# query parameters
|
|
1131
|
+
query_params = opts[:query_params] || {}
|
|
1132
|
+
|
|
1133
|
+
# header parameters
|
|
1134
|
+
header_params = opts[:header_params] || {}
|
|
1135
|
+
# HTTP header 'Accept' (if needed)
|
|
1136
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
1137
|
+
|
|
1138
|
+
# form parameters
|
|
1139
|
+
form_params = opts[:form_params] || {}
|
|
1140
|
+
|
|
1141
|
+
# http body (model)
|
|
1142
|
+
post_body = opts[:debug_body]
|
|
1143
|
+
|
|
1144
|
+
# return_type
|
|
1145
|
+
return_type = opts[:debug_return_type] || 'GetVolumeGroupMetadataById200Response'
|
|
1146
|
+
|
|
1147
|
+
# auth_names
|
|
1148
|
+
auth_names = opts[:debug_auth_names] || ['apiKeyAuthScheme', 'basicAuthScheme']
|
|
1149
|
+
|
|
1150
|
+
new_options = opts.merge(
|
|
1151
|
+
:operation => :"VolumeGroupsApi.get_volume_group_metadata_by_id",
|
|
1152
|
+
:header_params => header_params,
|
|
1153
|
+
:query_params => query_params,
|
|
1154
|
+
:form_params => form_params,
|
|
1155
|
+
:body => post_body,
|
|
1156
|
+
:auth_names => auth_names,
|
|
1157
|
+
:return_type => return_type
|
|
1158
|
+
)
|
|
1159
|
+
|
|
1160
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
1161
|
+
if @api_client.config.debugging
|
|
1162
|
+
@api_client.config.logger.debug "API called: VolumeGroupsApi#get_volume_group_metadata_by_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
1163
|
+
end
|
|
1164
|
+
return data, status_code, headers
|
|
1165
|
+
end
|
|
1166
|
+
|
|
1167
|
+
# Get statistics for a Volume Group
|
|
1168
|
+
# Query the Volume Group stats identified by {extId}.
|
|
1169
|
+
# @param ext_id [String] The external identifier of a Volume Group.
|
|
1170
|
+
# @param start_time [Time] The start time of the period for which stats should be reported. The value should be in extended ISO-8601 format. For example, start time of 2022-04-23T01:23:45.678+09:00 would consider all stats starting at 1:23:45.678 on the 23rd of April 2022. Details around ISO-8601 format can be found at https://www.iso.org/standard/70907.html
|
|
1171
|
+
# @param end_time [Time] The end time of the period for which stats should be reported. The value should be in extended ISO-8601 format. For example, end time of 2022-04-23T013:23:45.678+09:00 would consider all stats till 13:23:45 .678 on the 23rd of April 2022. Details around ISO-8601 format can be found at https://www.iso.org/standard/70907.html
|
|
1172
|
+
# @param [Hash] opts the optional parameters
|
|
1173
|
+
# @option opts [Integer] :sampling_interval The sampling interval in seconds at which statistical data should be collected. For example, if you want performance statistics every 30 seconds, then provide the value as 30.
|
|
1174
|
+
# @option opts [CommonV10StatsDownSamplingOperator] :stat_type
|
|
1175
|
+
# @option opts [String] :select A URL query parameter that allows clients to request a specific set of properties for each entity or complex type. Expression specified with the $select must conform to the [OData V4.01](https://docs.oasis-open.org/odata/odata/v4.01/odata-v4.01-part1-protocol.html) URL conventions. If a $select expression consists of a single select item that is an asterisk (i.e., *), then all properties on the matching resource will be returned. - controllerAvgIOLatencyUsecs - controllerAvgReadIOLatencyUsecs - controllerAvgWriteIOLatencyUsecs - controllerIOBandwidthKBps - controllerNumIOPS - controllerNumReadIOPS - controllerNumWriteIOPS - controllerReadIOBandwidthKBps - controllerUserBytes - controllerWriteIOBandwidthKBps
|
|
1176
|
+
# @return [GetVolumeGroupStats200Response]
|
|
1177
|
+
def get_volume_group_stats(ext_id, start_time, end_time, opts = {})
|
|
1178
|
+
data, _status_code, _headers = get_volume_group_stats_with_http_info(ext_id, start_time, end_time, opts)
|
|
1179
|
+
data
|
|
1180
|
+
end
|
|
1181
|
+
|
|
1182
|
+
# Get statistics for a Volume Group
|
|
1183
|
+
# Query the Volume Group stats identified by {extId}.
|
|
1184
|
+
# @param ext_id [String] The external identifier of a Volume Group.
|
|
1185
|
+
# @param start_time [Time] The start time of the period for which stats should be reported. The value should be in extended ISO-8601 format. For example, start time of 2022-04-23T01:23:45.678+09:00 would consider all stats starting at 1:23:45.678 on the 23rd of April 2022. Details around ISO-8601 format can be found at https://www.iso.org/standard/70907.html
|
|
1186
|
+
# @param end_time [Time] The end time of the period for which stats should be reported. The value should be in extended ISO-8601 format. For example, end time of 2022-04-23T013:23:45.678+09:00 would consider all stats till 13:23:45 .678 on the 23rd of April 2022. Details around ISO-8601 format can be found at https://www.iso.org/standard/70907.html
|
|
1187
|
+
# @param [Hash] opts the optional parameters
|
|
1188
|
+
# @option opts [Integer] :sampling_interval The sampling interval in seconds at which statistical data should be collected. For example, if you want performance statistics every 30 seconds, then provide the value as 30.
|
|
1189
|
+
# @option opts [CommonV10StatsDownSamplingOperator] :stat_type
|
|
1190
|
+
# @option opts [String] :select A URL query parameter that allows clients to request a specific set of properties for each entity or complex type. Expression specified with the $select must conform to the [OData V4.01](https://docs.oasis-open.org/odata/odata/v4.01/odata-v4.01-part1-protocol.html) URL conventions. If a $select expression consists of a single select item that is an asterisk (i.e., *), then all properties on the matching resource will be returned. - controllerAvgIOLatencyUsecs - controllerAvgReadIOLatencyUsecs - controllerAvgWriteIOLatencyUsecs - controllerIOBandwidthKBps - controllerNumIOPS - controllerNumReadIOPS - controllerNumWriteIOPS - controllerReadIOBandwidthKBps - controllerUserBytes - controllerWriteIOBandwidthKBps
|
|
1191
|
+
# @return [Array<(GetVolumeGroupStats200Response, Integer, Hash)>] GetVolumeGroupStats200Response data, response status code and response headers
|
|
1192
|
+
def get_volume_group_stats_with_http_info(ext_id, start_time, end_time, opts = {})
|
|
1193
|
+
if @api_client.config.debugging
|
|
1194
|
+
@api_client.config.logger.debug 'Calling API: VolumeGroupsApi.get_volume_group_stats ...'
|
|
1195
|
+
end
|
|
1196
|
+
# verify the required parameter 'ext_id' is set
|
|
1197
|
+
if @api_client.config.client_side_validation && ext_id.nil?
|
|
1198
|
+
fail ArgumentError, "Missing the required parameter 'ext_id' when calling VolumeGroupsApi.get_volume_group_stats"
|
|
1199
|
+
end
|
|
1200
|
+
pattern = Regexp.new(/^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$/)
|
|
1201
|
+
if @api_client.config.client_side_validation && ext_id !~ pattern
|
|
1202
|
+
fail ArgumentError, "invalid value for 'ext_id' when calling VolumeGroupsApi.get_volume_group_stats, must conform to the pattern #{pattern}."
|
|
1203
|
+
end
|
|
1204
|
+
|
|
1205
|
+
# verify the required parameter 'start_time' is set
|
|
1206
|
+
if @api_client.config.client_side_validation && start_time.nil?
|
|
1207
|
+
fail ArgumentError, "Missing the required parameter 'start_time' when calling VolumeGroupsApi.get_volume_group_stats"
|
|
1208
|
+
end
|
|
1209
|
+
# verify the required parameter 'end_time' is set
|
|
1210
|
+
if @api_client.config.client_side_validation && end_time.nil?
|
|
1211
|
+
fail ArgumentError, "Missing the required parameter 'end_time' when calling VolumeGroupsApi.get_volume_group_stats"
|
|
1212
|
+
end
|
|
1213
|
+
if @api_client.config.client_side_validation && !opts[:'sampling_interval'].nil? && opts[:'sampling_interval'] < 1
|
|
1214
|
+
fail ArgumentError, 'invalid value for "opts[:"sampling_interval"]" when calling VolumeGroupsApi.get_volume_group_stats, must be greater than or equal to 1.'
|
|
1215
|
+
end
|
|
1216
|
+
|
|
1217
|
+
# resource path
|
|
1218
|
+
local_var_path = '/volumes/v4.0/stats/volume-groups/{extId}'.sub('{' + 'extId' + '}', CGI.escape(ext_id.to_s))
|
|
1219
|
+
|
|
1220
|
+
# query parameters
|
|
1221
|
+
query_params = opts[:query_params] || {}
|
|
1222
|
+
query_params[:'$startTime'] = start_time
|
|
1223
|
+
query_params[:'$endTime'] = end_time
|
|
1224
|
+
query_params[:'$samplingInterval'] = opts[:'sampling_interval'] if !opts[:'sampling_interval'].nil?
|
|
1225
|
+
query_params[:'$statType'] = opts[:'stat_type'] if !opts[:'stat_type'].nil?
|
|
1226
|
+
query_params[:'$select'] = opts[:'select'] if !opts[:'select'].nil?
|
|
1227
|
+
|
|
1228
|
+
# header parameters
|
|
1229
|
+
header_params = opts[:header_params] || {}
|
|
1230
|
+
# HTTP header 'Accept' (if needed)
|
|
1231
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
1232
|
+
|
|
1233
|
+
# form parameters
|
|
1234
|
+
form_params = opts[:form_params] || {}
|
|
1235
|
+
|
|
1236
|
+
# http body (model)
|
|
1237
|
+
post_body = opts[:debug_body]
|
|
1238
|
+
|
|
1239
|
+
# return_type
|
|
1240
|
+
return_type = opts[:debug_return_type] || 'GetVolumeGroupStats200Response'
|
|
1241
|
+
|
|
1242
|
+
# auth_names
|
|
1243
|
+
auth_names = opts[:debug_auth_names] || ['apiKeyAuthScheme', 'basicAuthScheme']
|
|
1244
|
+
|
|
1245
|
+
new_options = opts.merge(
|
|
1246
|
+
:operation => :"VolumeGroupsApi.get_volume_group_stats",
|
|
1247
|
+
:header_params => header_params,
|
|
1248
|
+
:query_params => query_params,
|
|
1249
|
+
:form_params => form_params,
|
|
1250
|
+
:body => post_body,
|
|
1251
|
+
:auth_names => auth_names,
|
|
1252
|
+
:return_type => return_type
|
|
1253
|
+
)
|
|
1254
|
+
|
|
1255
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
1256
|
+
if @api_client.config.debugging
|
|
1257
|
+
@api_client.config.logger.debug "API called: VolumeGroupsApi#get_volume_group_stats\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
1258
|
+
end
|
|
1259
|
+
return data, status_code, headers
|
|
1260
|
+
end
|
|
1261
|
+
|
|
1262
|
+
# List all the category details that are associated with the Volume Group
|
|
1263
|
+
# Query the category details that are associated with the Volume Group identified by {volumeGroupExtId}.
|
|
1264
|
+
# @param volume_group_ext_id [String] The external identifier of a Volume Group.
|
|
1265
|
+
# @param [Hash] opts the optional parameters
|
|
1266
|
+
# @option opts [Integer] :page A URL query parameter that specifies the page number of the result set. It must be a positive integer between 0 and the maximum number of pages that are available for that resource. Any number out of this range might lead to no results. (default to 0)
|
|
1267
|
+
# @option opts [Integer] :limit A URL query parameter that specifies the total number of records returned in the result set. Must be a positive integer between 1 and 100. Any number out of this range will lead to a validation error. If the limit is not provided, a default value of 50 records will be returned in the result set. (default to 50)
|
|
1268
|
+
# @return [ListCategoryAssociationsByVolumeGroupId200Response]
|
|
1269
|
+
def list_category_associations_by_volume_group_id(volume_group_ext_id, opts = {})
|
|
1270
|
+
data, _status_code, _headers = list_category_associations_by_volume_group_id_with_http_info(volume_group_ext_id, opts)
|
|
1271
|
+
data
|
|
1272
|
+
end
|
|
1273
|
+
|
|
1274
|
+
# List all the category details that are associated with the Volume Group
|
|
1275
|
+
# Query the category details that are associated with the Volume Group identified by {volumeGroupExtId}.
|
|
1276
|
+
# @param volume_group_ext_id [String] The external identifier of a Volume Group.
|
|
1277
|
+
# @param [Hash] opts the optional parameters
|
|
1278
|
+
# @option opts [Integer] :page A URL query parameter that specifies the page number of the result set. It must be a positive integer between 0 and the maximum number of pages that are available for that resource. Any number out of this range might lead to no results. (default to 0)
|
|
1279
|
+
# @option opts [Integer] :limit A URL query parameter that specifies the total number of records returned in the result set. Must be a positive integer between 1 and 100. Any number out of this range will lead to a validation error. If the limit is not provided, a default value of 50 records will be returned in the result set. (default to 50)
|
|
1280
|
+
# @return [Array<(ListCategoryAssociationsByVolumeGroupId200Response, Integer, Hash)>] ListCategoryAssociationsByVolumeGroupId200Response data, response status code and response headers
|
|
1281
|
+
def list_category_associations_by_volume_group_id_with_http_info(volume_group_ext_id, opts = {})
|
|
1282
|
+
if @api_client.config.debugging
|
|
1283
|
+
@api_client.config.logger.debug 'Calling API: VolumeGroupsApi.list_category_associations_by_volume_group_id ...'
|
|
1284
|
+
end
|
|
1285
|
+
# verify the required parameter 'volume_group_ext_id' is set
|
|
1286
|
+
if @api_client.config.client_side_validation && volume_group_ext_id.nil?
|
|
1287
|
+
fail ArgumentError, "Missing the required parameter 'volume_group_ext_id' when calling VolumeGroupsApi.list_category_associations_by_volume_group_id"
|
|
1288
|
+
end
|
|
1289
|
+
pattern = Regexp.new(/^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$/)
|
|
1290
|
+
if @api_client.config.client_side_validation && volume_group_ext_id !~ pattern
|
|
1291
|
+
fail ArgumentError, "invalid value for 'volume_group_ext_id' when calling VolumeGroupsApi.list_category_associations_by_volume_group_id, must conform to the pattern #{pattern}."
|
|
1292
|
+
end
|
|
1293
|
+
|
|
1294
|
+
if @api_client.config.client_side_validation && !opts[:'page'].nil? && opts[:'page'] < 0
|
|
1295
|
+
fail ArgumentError, 'invalid value for "opts[:"page"]" when calling VolumeGroupsApi.list_category_associations_by_volume_group_id, must be greater than or equal to 0.'
|
|
1296
|
+
end
|
|
1297
|
+
|
|
1298
|
+
if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] > 100
|
|
1299
|
+
fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling VolumeGroupsApi.list_category_associations_by_volume_group_id, must be smaller than or equal to 100.'
|
|
1300
|
+
end
|
|
1301
|
+
|
|
1302
|
+
if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] < 1
|
|
1303
|
+
fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling VolumeGroupsApi.list_category_associations_by_volume_group_id, must be greater than or equal to 1.'
|
|
1304
|
+
end
|
|
1305
|
+
|
|
1306
|
+
# resource path
|
|
1307
|
+
local_var_path = '/volumes/v4.0/config/volume-groups/{volumeGroupExtId}/category-associations'.sub('{' + 'volumeGroupExtId' + '}', CGI.escape(volume_group_ext_id.to_s))
|
|
1308
|
+
|
|
1309
|
+
# query parameters
|
|
1310
|
+
query_params = opts[:query_params] || {}
|
|
1311
|
+
query_params[:'$page'] = opts[:'page'] if !opts[:'page'].nil?
|
|
1312
|
+
query_params[:'$limit'] = opts[:'limit'] if !opts[:'limit'].nil?
|
|
1313
|
+
|
|
1314
|
+
# header parameters
|
|
1315
|
+
header_params = opts[:header_params] || {}
|
|
1316
|
+
# HTTP header 'Accept' (if needed)
|
|
1317
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
1318
|
+
|
|
1319
|
+
# form parameters
|
|
1320
|
+
form_params = opts[:form_params] || {}
|
|
1321
|
+
|
|
1322
|
+
# http body (model)
|
|
1323
|
+
post_body = opts[:debug_body]
|
|
1324
|
+
|
|
1325
|
+
# return_type
|
|
1326
|
+
return_type = opts[:debug_return_type] || 'ListCategoryAssociationsByVolumeGroupId200Response'
|
|
1327
|
+
|
|
1328
|
+
# auth_names
|
|
1329
|
+
auth_names = opts[:debug_auth_names] || ['apiKeyAuthScheme', 'basicAuthScheme']
|
|
1330
|
+
|
|
1331
|
+
new_options = opts.merge(
|
|
1332
|
+
:operation => :"VolumeGroupsApi.list_category_associations_by_volume_group_id",
|
|
1333
|
+
:header_params => header_params,
|
|
1334
|
+
:query_params => query_params,
|
|
1335
|
+
:form_params => form_params,
|
|
1336
|
+
:body => post_body,
|
|
1337
|
+
:auth_names => auth_names,
|
|
1338
|
+
:return_type => return_type
|
|
1339
|
+
)
|
|
1340
|
+
|
|
1341
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
1342
|
+
if @api_client.config.debugging
|
|
1343
|
+
@api_client.config.logger.debug "API called: VolumeGroupsApi#list_category_associations_by_volume_group_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
1344
|
+
end
|
|
1345
|
+
return data, status_code, headers
|
|
1346
|
+
end
|
|
1347
|
+
|
|
1348
|
+
# List all the iSCSI attachments associated with the given Volume Group
|
|
1349
|
+
# Query the list of external iSCSI attachments for a Volume Group identified by {extId}.
|
|
1350
|
+
# @param volume_group_ext_id [String] The external identifier of a Volume Group.
|
|
1351
|
+
# @param [Hash] opts the optional parameters
|
|
1352
|
+
# @option opts [Integer] :page A URL query parameter that specifies the page number of the result set. It must be a positive integer between 0 and the maximum number of pages that are available for that resource. Any number out of this range might lead to no results. (default to 0)
|
|
1353
|
+
# @option opts [Integer] :limit A URL query parameter that specifies the total number of records returned in the result set. Must be a positive integer between 1 and 100. Any number out of this range will lead to a validation error. If the limit is not provided, a default value of 50 records will be returned in the result set. (default to 50)
|
|
1354
|
+
# @option opts [String] :filter A URL query parameter that allows clients to filter a collection of resources. The expression specified with $filter is evaluated for each resource in the collection, and only items where the expression evaluates to true are included in the response. Expression specified with the $filter must conform to the [OData V4.01](https://docs.oasis-open.org/odata/odata/v4.01/odata-v4.01-part1-protocol.html) URL conventions. For example, filter '$filter=name eq 'karbon-ntnx-1.0' would filter the result on cluster name 'karbon-ntnx1.0', filter '$filter=startswith(name, 'C')' would filter on cluster name starting with 'C'. The filter can be applied to the following fields: - clusterReference - extId
|
|
1355
|
+
# @option opts [String] :orderby A URL query parameter that allows clients to specify the sort criteria for the returned list of objects. Resources can be sorted in ascending order using asc or descending order using desc. If asc or desc are not specified, the resources will be sorted in ascending order by default. For example, '$orderby=templateName desc' would get all templates sorted by templateName in descending order. The orderby can be applied to the following fields: - clusterReference - extId
|
|
1356
|
+
# @option opts [String] :expand A URL query parameter that allows clients to request related resources when a resource that satisfies a particular request is retrieved. Each expanded item is evaluated relative to the entity containing the property being expanded. Other query options can be applied to an expanded property by appending a semicolon-separated list of query options, enclosed in parentheses, to the property name. Permissible system query options are $filter, $select and $orderby. The following expansion keys are supported. - iscsiClient
|
|
1357
|
+
# @option opts [String] :select A URL query parameter that allows clients to request a specific set of properties for each entity or complex type. Expression specified with the $select must conform to the [OData V4.01](https://docs.oasis-open.org/odata/odata/v4.01/odata-v4.01-part1-protocol.html) URL conventions. If a $select expression consists of a single select item that is an asterisk (i.e., *), then all properties on the matching resource will be returned. - clusterReference - extId
|
|
1358
|
+
# @return [ListExternalIscsiAttachmentsByVolumeGroupId200Response]
|
|
1359
|
+
def list_external_iscsi_attachments_by_volume_group_id(volume_group_ext_id, opts = {})
|
|
1360
|
+
data, _status_code, _headers = list_external_iscsi_attachments_by_volume_group_id_with_http_info(volume_group_ext_id, opts)
|
|
1361
|
+
data
|
|
1362
|
+
end
|
|
1363
|
+
|
|
1364
|
+
# List all the iSCSI attachments associated with the given Volume Group
|
|
1365
|
+
# Query the list of external iSCSI attachments for a Volume Group identified by {extId}.
|
|
1366
|
+
# @param volume_group_ext_id [String] The external identifier of a Volume Group.
|
|
1367
|
+
# @param [Hash] opts the optional parameters
|
|
1368
|
+
# @option opts [Integer] :page A URL query parameter that specifies the page number of the result set. It must be a positive integer between 0 and the maximum number of pages that are available for that resource. Any number out of this range might lead to no results. (default to 0)
|
|
1369
|
+
# @option opts [Integer] :limit A URL query parameter that specifies the total number of records returned in the result set. Must be a positive integer between 1 and 100. Any number out of this range will lead to a validation error. If the limit is not provided, a default value of 50 records will be returned in the result set. (default to 50)
|
|
1370
|
+
# @option opts [String] :filter A URL query parameter that allows clients to filter a collection of resources. The expression specified with $filter is evaluated for each resource in the collection, and only items where the expression evaluates to true are included in the response. Expression specified with the $filter must conform to the [OData V4.01](https://docs.oasis-open.org/odata/odata/v4.01/odata-v4.01-part1-protocol.html) URL conventions. For example, filter '$filter=name eq 'karbon-ntnx-1.0' would filter the result on cluster name 'karbon-ntnx1.0', filter '$filter=startswith(name, 'C')' would filter on cluster name starting with 'C'. The filter can be applied to the following fields: - clusterReference - extId
|
|
1371
|
+
# @option opts [String] :orderby A URL query parameter that allows clients to specify the sort criteria for the returned list of objects. Resources can be sorted in ascending order using asc or descending order using desc. If asc or desc are not specified, the resources will be sorted in ascending order by default. For example, '$orderby=templateName desc' would get all templates sorted by templateName in descending order. The orderby can be applied to the following fields: - clusterReference - extId
|
|
1372
|
+
# @option opts [String] :expand A URL query parameter that allows clients to request related resources when a resource that satisfies a particular request is retrieved. Each expanded item is evaluated relative to the entity containing the property being expanded. Other query options can be applied to an expanded property by appending a semicolon-separated list of query options, enclosed in parentheses, to the property name. Permissible system query options are $filter, $select and $orderby. The following expansion keys are supported. - iscsiClient
|
|
1373
|
+
# @option opts [String] :select A URL query parameter that allows clients to request a specific set of properties for each entity or complex type. Expression specified with the $select must conform to the [OData V4.01](https://docs.oasis-open.org/odata/odata/v4.01/odata-v4.01-part1-protocol.html) URL conventions. If a $select expression consists of a single select item that is an asterisk (i.e., *), then all properties on the matching resource will be returned. - clusterReference - extId
|
|
1374
|
+
# @return [Array<(ListExternalIscsiAttachmentsByVolumeGroupId200Response, Integer, Hash)>] ListExternalIscsiAttachmentsByVolumeGroupId200Response data, response status code and response headers
|
|
1375
|
+
def list_external_iscsi_attachments_by_volume_group_id_with_http_info(volume_group_ext_id, opts = {})
|
|
1376
|
+
if @api_client.config.debugging
|
|
1377
|
+
@api_client.config.logger.debug 'Calling API: VolumeGroupsApi.list_external_iscsi_attachments_by_volume_group_id ...'
|
|
1378
|
+
end
|
|
1379
|
+
# verify the required parameter 'volume_group_ext_id' is set
|
|
1380
|
+
if @api_client.config.client_side_validation && volume_group_ext_id.nil?
|
|
1381
|
+
fail ArgumentError, "Missing the required parameter 'volume_group_ext_id' when calling VolumeGroupsApi.list_external_iscsi_attachments_by_volume_group_id"
|
|
1382
|
+
end
|
|
1383
|
+
pattern = Regexp.new(/^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$/)
|
|
1384
|
+
if @api_client.config.client_side_validation && volume_group_ext_id !~ pattern
|
|
1385
|
+
fail ArgumentError, "invalid value for 'volume_group_ext_id' when calling VolumeGroupsApi.list_external_iscsi_attachments_by_volume_group_id, must conform to the pattern #{pattern}."
|
|
1386
|
+
end
|
|
1387
|
+
|
|
1388
|
+
if @api_client.config.client_side_validation && !opts[:'page'].nil? && opts[:'page'] < 0
|
|
1389
|
+
fail ArgumentError, 'invalid value for "opts[:"page"]" when calling VolumeGroupsApi.list_external_iscsi_attachments_by_volume_group_id, must be greater than or equal to 0.'
|
|
1390
|
+
end
|
|
1391
|
+
|
|
1392
|
+
if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] > 100
|
|
1393
|
+
fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling VolumeGroupsApi.list_external_iscsi_attachments_by_volume_group_id, must be smaller than or equal to 100.'
|
|
1394
|
+
end
|
|
1395
|
+
|
|
1396
|
+
if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] < 1
|
|
1397
|
+
fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling VolumeGroupsApi.list_external_iscsi_attachments_by_volume_group_id, must be greater than or equal to 1.'
|
|
1398
|
+
end
|
|
1399
|
+
|
|
1400
|
+
# resource path
|
|
1401
|
+
local_var_path = '/volumes/v4.0/config/volume-groups/{volumeGroupExtId}/external-iscsi-attachments'.sub('{' + 'volumeGroupExtId' + '}', CGI.escape(volume_group_ext_id.to_s))
|
|
1402
|
+
|
|
1403
|
+
# query parameters
|
|
1404
|
+
query_params = opts[:query_params] || {}
|
|
1405
|
+
query_params[:'$page'] = opts[:'page'] if !opts[:'page'].nil?
|
|
1406
|
+
query_params[:'$limit'] = opts[:'limit'] if !opts[:'limit'].nil?
|
|
1407
|
+
query_params[:'$filter'] = opts[:'filter'] if !opts[:'filter'].nil?
|
|
1408
|
+
query_params[:'$orderby'] = opts[:'orderby'] if !opts[:'orderby'].nil?
|
|
1409
|
+
query_params[:'$expand'] = opts[:'expand'] if !opts[:'expand'].nil?
|
|
1410
|
+
query_params[:'$select'] = opts[:'select'] if !opts[:'select'].nil?
|
|
1411
|
+
|
|
1412
|
+
# header parameters
|
|
1413
|
+
header_params = opts[:header_params] || {}
|
|
1414
|
+
# HTTP header 'Accept' (if needed)
|
|
1415
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
1416
|
+
|
|
1417
|
+
# form parameters
|
|
1418
|
+
form_params = opts[:form_params] || {}
|
|
1419
|
+
|
|
1420
|
+
# http body (model)
|
|
1421
|
+
post_body = opts[:debug_body]
|
|
1422
|
+
|
|
1423
|
+
# return_type
|
|
1424
|
+
return_type = opts[:debug_return_type] || 'ListExternalIscsiAttachmentsByVolumeGroupId200Response'
|
|
1425
|
+
|
|
1426
|
+
# auth_names
|
|
1427
|
+
auth_names = opts[:debug_auth_names] || ['apiKeyAuthScheme', 'basicAuthScheme']
|
|
1428
|
+
|
|
1429
|
+
new_options = opts.merge(
|
|
1430
|
+
:operation => :"VolumeGroupsApi.list_external_iscsi_attachments_by_volume_group_id",
|
|
1431
|
+
:header_params => header_params,
|
|
1432
|
+
:query_params => query_params,
|
|
1433
|
+
:form_params => form_params,
|
|
1434
|
+
:body => post_body,
|
|
1435
|
+
:auth_names => auth_names,
|
|
1436
|
+
:return_type => return_type
|
|
1437
|
+
)
|
|
1438
|
+
|
|
1439
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
1440
|
+
if @api_client.config.debugging
|
|
1441
|
+
@api_client.config.logger.debug "API called: VolumeGroupsApi#list_external_iscsi_attachments_by_volume_group_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
1442
|
+
end
|
|
1443
|
+
return data, status_code, headers
|
|
1444
|
+
end
|
|
1445
|
+
|
|
1446
|
+
# List all the VM attachments for a Volume Group
|
|
1447
|
+
# Query the list of VM attachments for a Volume Group identified by {extId}.
|
|
1448
|
+
# @param volume_group_ext_id [String] The external identifier of a Volume Group.
|
|
1449
|
+
# @param [Hash] opts the optional parameters
|
|
1450
|
+
# @option opts [Integer] :page A URL query parameter that specifies the page number of the result set. It must be a positive integer between 0 and the maximum number of pages that are available for that resource. Any number out of this range might lead to no results. (default to 0)
|
|
1451
|
+
# @option opts [Integer] :limit A URL query parameter that specifies the total number of records returned in the result set. Must be a positive integer between 1 and 100. Any number out of this range will lead to a validation error. If the limit is not provided, a default value of 50 records will be returned in the result set. (default to 50)
|
|
1452
|
+
# @option opts [String] :filter A URL query parameter that allows clients to filter a collection of resources. The expression specified with $filter is evaluated for each resource in the collection, and only items where the expression evaluates to true are included in the response. Expression specified with the $filter must conform to the [OData V4.01](https://docs.oasis-open.org/odata/odata/v4.01/odata-v4.01-part1-protocol.html) URL conventions. For example, filter '$filter=name eq 'karbon-ntnx-1.0' would filter the result on cluster name 'karbon-ntnx1.0', filter '$filter=startswith(name, 'C')' would filter on cluster name starting with 'C'. The filter can be applied to the following fields: - extId
|
|
1453
|
+
# @option opts [String] :orderby A URL query parameter that allows clients to specify the sort criteria for the returned list of objects. Resources can be sorted in ascending order using asc or descending order using desc. If asc or desc are not specified, the resources will be sorted in ascending order by default. For example, '$orderby=templateName desc' would get all templates sorted by templateName in descending order. The orderby can be applied to the following fields: - extId
|
|
1454
|
+
# @return [ListVmAttachmentsByVolumeGroupId200Response]
|
|
1455
|
+
def list_vm_attachments_by_volume_group_id(volume_group_ext_id, opts = {})
|
|
1456
|
+
data, _status_code, _headers = list_vm_attachments_by_volume_group_id_with_http_info(volume_group_ext_id, opts)
|
|
1457
|
+
data
|
|
1458
|
+
end
|
|
1459
|
+
|
|
1460
|
+
# List all the VM attachments for a Volume Group
|
|
1461
|
+
# Query the list of VM attachments for a Volume Group identified by {extId}.
|
|
1462
|
+
# @param volume_group_ext_id [String] The external identifier of a Volume Group.
|
|
1463
|
+
# @param [Hash] opts the optional parameters
|
|
1464
|
+
# @option opts [Integer] :page A URL query parameter that specifies the page number of the result set. It must be a positive integer between 0 and the maximum number of pages that are available for that resource. Any number out of this range might lead to no results. (default to 0)
|
|
1465
|
+
# @option opts [Integer] :limit A URL query parameter that specifies the total number of records returned in the result set. Must be a positive integer between 1 and 100. Any number out of this range will lead to a validation error. If the limit is not provided, a default value of 50 records will be returned in the result set. (default to 50)
|
|
1466
|
+
# @option opts [String] :filter A URL query parameter that allows clients to filter a collection of resources. The expression specified with $filter is evaluated for each resource in the collection, and only items where the expression evaluates to true are included in the response. Expression specified with the $filter must conform to the [OData V4.01](https://docs.oasis-open.org/odata/odata/v4.01/odata-v4.01-part1-protocol.html) URL conventions. For example, filter '$filter=name eq 'karbon-ntnx-1.0' would filter the result on cluster name 'karbon-ntnx1.0', filter '$filter=startswith(name, 'C')' would filter on cluster name starting with 'C'. The filter can be applied to the following fields: - extId
|
|
1467
|
+
# @option opts [String] :orderby A URL query parameter that allows clients to specify the sort criteria for the returned list of objects. Resources can be sorted in ascending order using asc or descending order using desc. If asc or desc are not specified, the resources will be sorted in ascending order by default. For example, '$orderby=templateName desc' would get all templates sorted by templateName in descending order. The orderby can be applied to the following fields: - extId
|
|
1468
|
+
# @return [Array<(ListVmAttachmentsByVolumeGroupId200Response, Integer, Hash)>] ListVmAttachmentsByVolumeGroupId200Response data, response status code and response headers
|
|
1469
|
+
def list_vm_attachments_by_volume_group_id_with_http_info(volume_group_ext_id, opts = {})
|
|
1470
|
+
if @api_client.config.debugging
|
|
1471
|
+
@api_client.config.logger.debug 'Calling API: VolumeGroupsApi.list_vm_attachments_by_volume_group_id ...'
|
|
1472
|
+
end
|
|
1473
|
+
# verify the required parameter 'volume_group_ext_id' is set
|
|
1474
|
+
if @api_client.config.client_side_validation && volume_group_ext_id.nil?
|
|
1475
|
+
fail ArgumentError, "Missing the required parameter 'volume_group_ext_id' when calling VolumeGroupsApi.list_vm_attachments_by_volume_group_id"
|
|
1476
|
+
end
|
|
1477
|
+
pattern = Regexp.new(/^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$/)
|
|
1478
|
+
if @api_client.config.client_side_validation && volume_group_ext_id !~ pattern
|
|
1479
|
+
fail ArgumentError, "invalid value for 'volume_group_ext_id' when calling VolumeGroupsApi.list_vm_attachments_by_volume_group_id, must conform to the pattern #{pattern}."
|
|
1480
|
+
end
|
|
1481
|
+
|
|
1482
|
+
if @api_client.config.client_side_validation && !opts[:'page'].nil? && opts[:'page'] < 0
|
|
1483
|
+
fail ArgumentError, 'invalid value for "opts[:"page"]" when calling VolumeGroupsApi.list_vm_attachments_by_volume_group_id, must be greater than or equal to 0.'
|
|
1484
|
+
end
|
|
1485
|
+
|
|
1486
|
+
if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] > 100
|
|
1487
|
+
fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling VolumeGroupsApi.list_vm_attachments_by_volume_group_id, must be smaller than or equal to 100.'
|
|
1488
|
+
end
|
|
1489
|
+
|
|
1490
|
+
if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] < 1
|
|
1491
|
+
fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling VolumeGroupsApi.list_vm_attachments_by_volume_group_id, must be greater than or equal to 1.'
|
|
1492
|
+
end
|
|
1493
|
+
|
|
1494
|
+
# resource path
|
|
1495
|
+
local_var_path = '/volumes/v4.0/config/volume-groups/{volumeGroupExtId}/vm-attachments'.sub('{' + 'volumeGroupExtId' + '}', CGI.escape(volume_group_ext_id.to_s))
|
|
1496
|
+
|
|
1497
|
+
# query parameters
|
|
1498
|
+
query_params = opts[:query_params] || {}
|
|
1499
|
+
query_params[:'$page'] = opts[:'page'] if !opts[:'page'].nil?
|
|
1500
|
+
query_params[:'$limit'] = opts[:'limit'] if !opts[:'limit'].nil?
|
|
1501
|
+
query_params[:'$filter'] = opts[:'filter'] if !opts[:'filter'].nil?
|
|
1502
|
+
query_params[:'$orderby'] = opts[:'orderby'] if !opts[:'orderby'].nil?
|
|
1503
|
+
|
|
1504
|
+
# header parameters
|
|
1505
|
+
header_params = opts[:header_params] || {}
|
|
1506
|
+
# HTTP header 'Accept' (if needed)
|
|
1507
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
1508
|
+
|
|
1509
|
+
# form parameters
|
|
1510
|
+
form_params = opts[:form_params] || {}
|
|
1511
|
+
|
|
1512
|
+
# http body (model)
|
|
1513
|
+
post_body = opts[:debug_body]
|
|
1514
|
+
|
|
1515
|
+
# return_type
|
|
1516
|
+
return_type = opts[:debug_return_type] || 'ListVmAttachmentsByVolumeGroupId200Response'
|
|
1517
|
+
|
|
1518
|
+
# auth_names
|
|
1519
|
+
auth_names = opts[:debug_auth_names] || ['apiKeyAuthScheme', 'basicAuthScheme']
|
|
1520
|
+
|
|
1521
|
+
new_options = opts.merge(
|
|
1522
|
+
:operation => :"VolumeGroupsApi.list_vm_attachments_by_volume_group_id",
|
|
1523
|
+
:header_params => header_params,
|
|
1524
|
+
:query_params => query_params,
|
|
1525
|
+
:form_params => form_params,
|
|
1526
|
+
:body => post_body,
|
|
1527
|
+
:auth_names => auth_names,
|
|
1528
|
+
:return_type => return_type
|
|
1529
|
+
)
|
|
1530
|
+
|
|
1531
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
1532
|
+
if @api_client.config.debugging
|
|
1533
|
+
@api_client.config.logger.debug "API called: VolumeGroupsApi#list_vm_attachments_by_volume_group_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
1534
|
+
end
|
|
1535
|
+
return data, status_code, headers
|
|
1536
|
+
end
|
|
1537
|
+
|
|
1538
|
+
# List all the Volume Disks attached to the Volume Group
|
|
1539
|
+
# Query the list of disks corresponding to a Volume Group identified by {volumeGroupExtId}.
|
|
1540
|
+
# @param volume_group_ext_id [String] The external identifier of a Volume Group.
|
|
1541
|
+
# @param [Hash] opts the optional parameters
|
|
1542
|
+
# @option opts [Integer] :page A URL query parameter that specifies the page number of the result set. It must be a positive integer between 0 and the maximum number of pages that are available for that resource. Any number out of this range might lead to no results. (default to 0)
|
|
1543
|
+
# @option opts [Integer] :limit A URL query parameter that specifies the total number of records returned in the result set. Must be a positive integer between 1 and 100. Any number out of this range will lead to a validation error. If the limit is not provided, a default value of 50 records will be returned in the result set. (default to 50)
|
|
1544
|
+
# @option opts [String] :filter A URL query parameter that allows clients to filter a collection of resources. The expression specified with $filter is evaluated for each resource in the collection, and only items where the expression evaluates to true are included in the response. Expression specified with the $filter must conform to the [OData V4.01](https://docs.oasis-open.org/odata/odata/v4.01/odata-v4.01-part1-protocol.html) URL conventions. For example, filter '$filter=name eq 'karbon-ntnx-1.0' would filter the result on cluster name 'karbon-ntnx1.0', filter '$filter=startswith(name, 'C')' would filter on cluster name starting with 'C'. The filter can be applied to the following fields: - storageContainerId
|
|
1545
|
+
# @option opts [String] :orderby A URL query parameter that allows clients to specify the sort criteria for the returned list of objects. Resources can be sorted in ascending order using asc or descending order using desc. If asc or desc are not specified, the resources will be sorted in ascending order by default. For example, '$orderby=templateName desc' would get all templates sorted by templateName in descending order. The orderby can be applied to the following fields: - diskSizeBytes
|
|
1546
|
+
# @option opts [String] :select A URL query parameter that allows clients to request a specific set of properties for each entity or complex type. Expression specified with the $select must conform to the [OData V4.01](https://docs.oasis-open.org/odata/odata/v4.01/odata-v4.01-part1-protocol.html) URL conventions. If a $select expression consists of a single select item that is an asterisk (i.e., *), then all properties on the matching resource will be returned. - extId - storageContainerId
|
|
1547
|
+
# @return [ListVolumeDisksByVolumeGroupId200Response]
|
|
1548
|
+
def list_volume_disks_by_volume_group_id(volume_group_ext_id, opts = {})
|
|
1549
|
+
data, _status_code, _headers = list_volume_disks_by_volume_group_id_with_http_info(volume_group_ext_id, opts)
|
|
1550
|
+
data
|
|
1551
|
+
end
|
|
1552
|
+
|
|
1553
|
+
# List all the Volume Disks attached to the Volume Group
|
|
1554
|
+
# Query the list of disks corresponding to a Volume Group identified by {volumeGroupExtId}.
|
|
1555
|
+
# @param volume_group_ext_id [String] The external identifier of a Volume Group.
|
|
1556
|
+
# @param [Hash] opts the optional parameters
|
|
1557
|
+
# @option opts [Integer] :page A URL query parameter that specifies the page number of the result set. It must be a positive integer between 0 and the maximum number of pages that are available for that resource. Any number out of this range might lead to no results. (default to 0)
|
|
1558
|
+
# @option opts [Integer] :limit A URL query parameter that specifies the total number of records returned in the result set. Must be a positive integer between 1 and 100. Any number out of this range will lead to a validation error. If the limit is not provided, a default value of 50 records will be returned in the result set. (default to 50)
|
|
1559
|
+
# @option opts [String] :filter A URL query parameter that allows clients to filter a collection of resources. The expression specified with $filter is evaluated for each resource in the collection, and only items where the expression evaluates to true are included in the response. Expression specified with the $filter must conform to the [OData V4.01](https://docs.oasis-open.org/odata/odata/v4.01/odata-v4.01-part1-protocol.html) URL conventions. For example, filter '$filter=name eq 'karbon-ntnx-1.0' would filter the result on cluster name 'karbon-ntnx1.0', filter '$filter=startswith(name, 'C')' would filter on cluster name starting with 'C'. The filter can be applied to the following fields: - storageContainerId
|
|
1560
|
+
# @option opts [String] :orderby A URL query parameter that allows clients to specify the sort criteria for the returned list of objects. Resources can be sorted in ascending order using asc or descending order using desc. If asc or desc are not specified, the resources will be sorted in ascending order by default. For example, '$orderby=templateName desc' would get all templates sorted by templateName in descending order. The orderby can be applied to the following fields: - diskSizeBytes
|
|
1561
|
+
# @option opts [String] :select A URL query parameter that allows clients to request a specific set of properties for each entity or complex type. Expression specified with the $select must conform to the [OData V4.01](https://docs.oasis-open.org/odata/odata/v4.01/odata-v4.01-part1-protocol.html) URL conventions. If a $select expression consists of a single select item that is an asterisk (i.e., *), then all properties on the matching resource will be returned. - extId - storageContainerId
|
|
1562
|
+
# @return [Array<(ListVolumeDisksByVolumeGroupId200Response, Integer, Hash)>] ListVolumeDisksByVolumeGroupId200Response data, response status code and response headers
|
|
1563
|
+
def list_volume_disks_by_volume_group_id_with_http_info(volume_group_ext_id, opts = {})
|
|
1564
|
+
if @api_client.config.debugging
|
|
1565
|
+
@api_client.config.logger.debug 'Calling API: VolumeGroupsApi.list_volume_disks_by_volume_group_id ...'
|
|
1566
|
+
end
|
|
1567
|
+
# verify the required parameter 'volume_group_ext_id' is set
|
|
1568
|
+
if @api_client.config.client_side_validation && volume_group_ext_id.nil?
|
|
1569
|
+
fail ArgumentError, "Missing the required parameter 'volume_group_ext_id' when calling VolumeGroupsApi.list_volume_disks_by_volume_group_id"
|
|
1570
|
+
end
|
|
1571
|
+
pattern = Regexp.new(/^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$/)
|
|
1572
|
+
if @api_client.config.client_side_validation && volume_group_ext_id !~ pattern
|
|
1573
|
+
fail ArgumentError, "invalid value for 'volume_group_ext_id' when calling VolumeGroupsApi.list_volume_disks_by_volume_group_id, must conform to the pattern #{pattern}."
|
|
1574
|
+
end
|
|
1575
|
+
|
|
1576
|
+
if @api_client.config.client_side_validation && !opts[:'page'].nil? && opts[:'page'] < 0
|
|
1577
|
+
fail ArgumentError, 'invalid value for "opts[:"page"]" when calling VolumeGroupsApi.list_volume_disks_by_volume_group_id, must be greater than or equal to 0.'
|
|
1578
|
+
end
|
|
1579
|
+
|
|
1580
|
+
if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] > 100
|
|
1581
|
+
fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling VolumeGroupsApi.list_volume_disks_by_volume_group_id, must be smaller than or equal to 100.'
|
|
1582
|
+
end
|
|
1583
|
+
|
|
1584
|
+
if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] < 1
|
|
1585
|
+
fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling VolumeGroupsApi.list_volume_disks_by_volume_group_id, must be greater than or equal to 1.'
|
|
1586
|
+
end
|
|
1587
|
+
|
|
1588
|
+
# resource path
|
|
1589
|
+
local_var_path = '/volumes/v4.0/config/volume-groups/{volumeGroupExtId}/disks'.sub('{' + 'volumeGroupExtId' + '}', CGI.escape(volume_group_ext_id.to_s))
|
|
1590
|
+
|
|
1591
|
+
# query parameters
|
|
1592
|
+
query_params = opts[:query_params] || {}
|
|
1593
|
+
query_params[:'$page'] = opts[:'page'] if !opts[:'page'].nil?
|
|
1594
|
+
query_params[:'$limit'] = opts[:'limit'] if !opts[:'limit'].nil?
|
|
1595
|
+
query_params[:'$filter'] = opts[:'filter'] if !opts[:'filter'].nil?
|
|
1596
|
+
query_params[:'$orderby'] = opts[:'orderby'] if !opts[:'orderby'].nil?
|
|
1597
|
+
query_params[:'$select'] = opts[:'select'] if !opts[:'select'].nil?
|
|
1598
|
+
|
|
1599
|
+
# header parameters
|
|
1600
|
+
header_params = opts[:header_params] || {}
|
|
1601
|
+
# HTTP header 'Accept' (if needed)
|
|
1602
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
1603
|
+
|
|
1604
|
+
# form parameters
|
|
1605
|
+
form_params = opts[:form_params] || {}
|
|
1606
|
+
|
|
1607
|
+
# http body (model)
|
|
1608
|
+
post_body = opts[:debug_body]
|
|
1609
|
+
|
|
1610
|
+
# return_type
|
|
1611
|
+
return_type = opts[:debug_return_type] || 'ListVolumeDisksByVolumeGroupId200Response'
|
|
1612
|
+
|
|
1613
|
+
# auth_names
|
|
1614
|
+
auth_names = opts[:debug_auth_names] || ['apiKeyAuthScheme', 'basicAuthScheme']
|
|
1615
|
+
|
|
1616
|
+
new_options = opts.merge(
|
|
1617
|
+
:operation => :"VolumeGroupsApi.list_volume_disks_by_volume_group_id",
|
|
1618
|
+
:header_params => header_params,
|
|
1619
|
+
:query_params => query_params,
|
|
1620
|
+
:form_params => form_params,
|
|
1621
|
+
:body => post_body,
|
|
1622
|
+
:auth_names => auth_names,
|
|
1623
|
+
:return_type => return_type
|
|
1624
|
+
)
|
|
1625
|
+
|
|
1626
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
1627
|
+
if @api_client.config.debugging
|
|
1628
|
+
@api_client.config.logger.debug "API called: VolumeGroupsApi#list_volume_disks_by_volume_group_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
1629
|
+
end
|
|
1630
|
+
return data, status_code, headers
|
|
1631
|
+
end
|
|
1632
|
+
|
|
1633
|
+
# List all the Volume Groups
|
|
1634
|
+
# Query the list of Volume Groups.
|
|
1635
|
+
# @param [Hash] opts the optional parameters
|
|
1636
|
+
# @option opts [Integer] :page A URL query parameter that specifies the page number of the result set. It must be a positive integer between 0 and the maximum number of pages that are available for that resource. Any number out of this range might lead to no results. (default to 0)
|
|
1637
|
+
# @option opts [Integer] :limit A URL query parameter that specifies the total number of records returned in the result set. Must be a positive integer between 1 and 100. Any number out of this range will lead to a validation error. If the limit is not provided, a default value of 50 records will be returned in the result set. (default to 50)
|
|
1638
|
+
# @option opts [String] :filter A URL query parameter that allows clients to filter a collection of resources. The expression specified with $filter is evaluated for each resource in the collection, and only items where the expression evaluates to true are included in the response. Expression specified with the $filter must conform to the [OData V4.01](https://docs.oasis-open.org/odata/odata/v4.01/odata-v4.01-part1-protocol.html) URL conventions. For example, filter '$filter=name eq 'karbon-ntnx-1.0' would filter the result on cluster name 'karbon-ntnx1.0', filter '$filter=startswith(name, 'C')' would filter on cluster name starting with 'C'. The filter can be applied to the following fields: - clusterReference - extId - name
|
|
1639
|
+
# @option opts [String] :orderby A URL query parameter that allows clients to specify the sort criteria for the returned list of objects. Resources can be sorted in ascending order using asc or descending order using desc. If asc or desc are not specified, the resources will be sorted in ascending order by default. For example, '$orderby=templateName desc' would get all templates sorted by templateName in descending order. The orderby can be applied to the following fields: - clusterReference - extId - name
|
|
1640
|
+
# @option opts [String] :expand A URL query parameter that allows clients to request related resources when a resource that satisfies a particular request is retrieved. Each expanded item is evaluated relative to the entity containing the property being expanded. Other query options can be applied to an expanded property by appending a semicolon-separated list of query options, enclosed in parentheses, to the property name. Permissible system query options are $filter, $select and $orderby. The following expansion keys are supported. - cluster - metadata
|
|
1641
|
+
# @option opts [String] :select A URL query parameter that allows clients to request a specific set of properties for each entity or complex type. Expression specified with the $select must conform to the [OData V4.01](https://docs.oasis-open.org/odata/odata/v4.01/odata-v4.01-part1-protocol.html) URL conventions. If a $select expression consists of a single select item that is an asterisk (i.e., *), then all properties on the matching resource will be returned. - clusterReference - extId - name
|
|
1642
|
+
# @return [ListVolumeGroups200Response]
|
|
1643
|
+
def list_volume_groups(opts = {})
|
|
1644
|
+
data, _status_code, _headers = list_volume_groups_with_http_info(opts)
|
|
1645
|
+
data
|
|
1646
|
+
end
|
|
1647
|
+
|
|
1648
|
+
# List all the Volume Groups
|
|
1649
|
+
# Query the list of Volume Groups.
|
|
1650
|
+
# @param [Hash] opts the optional parameters
|
|
1651
|
+
# @option opts [Integer] :page A URL query parameter that specifies the page number of the result set. It must be a positive integer between 0 and the maximum number of pages that are available for that resource. Any number out of this range might lead to no results. (default to 0)
|
|
1652
|
+
# @option opts [Integer] :limit A URL query parameter that specifies the total number of records returned in the result set. Must be a positive integer between 1 and 100. Any number out of this range will lead to a validation error. If the limit is not provided, a default value of 50 records will be returned in the result set. (default to 50)
|
|
1653
|
+
# @option opts [String] :filter A URL query parameter that allows clients to filter a collection of resources. The expression specified with $filter is evaluated for each resource in the collection, and only items where the expression evaluates to true are included in the response. Expression specified with the $filter must conform to the [OData V4.01](https://docs.oasis-open.org/odata/odata/v4.01/odata-v4.01-part1-protocol.html) URL conventions. For example, filter '$filter=name eq 'karbon-ntnx-1.0' would filter the result on cluster name 'karbon-ntnx1.0', filter '$filter=startswith(name, 'C')' would filter on cluster name starting with 'C'. The filter can be applied to the following fields: - clusterReference - extId - name
|
|
1654
|
+
# @option opts [String] :orderby A URL query parameter that allows clients to specify the sort criteria for the returned list of objects. Resources can be sorted in ascending order using asc or descending order using desc. If asc or desc are not specified, the resources will be sorted in ascending order by default. For example, '$orderby=templateName desc' would get all templates sorted by templateName in descending order. The orderby can be applied to the following fields: - clusterReference - extId - name
|
|
1655
|
+
# @option opts [String] :expand A URL query parameter that allows clients to request related resources when a resource that satisfies a particular request is retrieved. Each expanded item is evaluated relative to the entity containing the property being expanded. Other query options can be applied to an expanded property by appending a semicolon-separated list of query options, enclosed in parentheses, to the property name. Permissible system query options are $filter, $select and $orderby. The following expansion keys are supported. - cluster - metadata
|
|
1656
|
+
# @option opts [String] :select A URL query parameter that allows clients to request a specific set of properties for each entity or complex type. Expression specified with the $select must conform to the [OData V4.01](https://docs.oasis-open.org/odata/odata/v4.01/odata-v4.01-part1-protocol.html) URL conventions. If a $select expression consists of a single select item that is an asterisk (i.e., *), then all properties on the matching resource will be returned. - clusterReference - extId - name
|
|
1657
|
+
# @return [Array<(ListVolumeGroups200Response, Integer, Hash)>] ListVolumeGroups200Response data, response status code and response headers
|
|
1658
|
+
def list_volume_groups_with_http_info(opts = {})
|
|
1659
|
+
if @api_client.config.debugging
|
|
1660
|
+
@api_client.config.logger.debug 'Calling API: VolumeGroupsApi.list_volume_groups ...'
|
|
1661
|
+
end
|
|
1662
|
+
if @api_client.config.client_side_validation && !opts[:'page'].nil? && opts[:'page'] < 0
|
|
1663
|
+
fail ArgumentError, 'invalid value for "opts[:"page"]" when calling VolumeGroupsApi.list_volume_groups, must be greater than or equal to 0.'
|
|
1664
|
+
end
|
|
1665
|
+
|
|
1666
|
+
if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] > 100
|
|
1667
|
+
fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling VolumeGroupsApi.list_volume_groups, must be smaller than or equal to 100.'
|
|
1668
|
+
end
|
|
1669
|
+
|
|
1670
|
+
if @api_client.config.client_side_validation && !opts[:'limit'].nil? && opts[:'limit'] < 1
|
|
1671
|
+
fail ArgumentError, 'invalid value for "opts[:"limit"]" when calling VolumeGroupsApi.list_volume_groups, must be greater than or equal to 1.'
|
|
1672
|
+
end
|
|
1673
|
+
|
|
1674
|
+
# resource path
|
|
1675
|
+
local_var_path = '/volumes/v4.0/config/volume-groups'
|
|
1676
|
+
|
|
1677
|
+
# query parameters
|
|
1678
|
+
query_params = opts[:query_params] || {}
|
|
1679
|
+
query_params[:'$page'] = opts[:'page'] if !opts[:'page'].nil?
|
|
1680
|
+
query_params[:'$limit'] = opts[:'limit'] if !opts[:'limit'].nil?
|
|
1681
|
+
query_params[:'$filter'] = opts[:'filter'] if !opts[:'filter'].nil?
|
|
1682
|
+
query_params[:'$orderby'] = opts[:'orderby'] if !opts[:'orderby'].nil?
|
|
1683
|
+
query_params[:'$expand'] = opts[:'expand'] if !opts[:'expand'].nil?
|
|
1684
|
+
query_params[:'$select'] = opts[:'select'] if !opts[:'select'].nil?
|
|
1685
|
+
|
|
1686
|
+
# header parameters
|
|
1687
|
+
header_params = opts[:header_params] || {}
|
|
1688
|
+
# HTTP header 'Accept' (if needed)
|
|
1689
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
1690
|
+
|
|
1691
|
+
# form parameters
|
|
1692
|
+
form_params = opts[:form_params] || {}
|
|
1693
|
+
|
|
1694
|
+
# http body (model)
|
|
1695
|
+
post_body = opts[:debug_body]
|
|
1696
|
+
|
|
1697
|
+
# return_type
|
|
1698
|
+
return_type = opts[:debug_return_type] || 'ListVolumeGroups200Response'
|
|
1699
|
+
|
|
1700
|
+
# auth_names
|
|
1701
|
+
auth_names = opts[:debug_auth_names] || ['apiKeyAuthScheme', 'basicAuthScheme']
|
|
1702
|
+
|
|
1703
|
+
new_options = opts.merge(
|
|
1704
|
+
:operation => :"VolumeGroupsApi.list_volume_groups",
|
|
1705
|
+
:header_params => header_params,
|
|
1706
|
+
:query_params => query_params,
|
|
1707
|
+
:form_params => form_params,
|
|
1708
|
+
:body => post_body,
|
|
1709
|
+
:auth_names => auth_names,
|
|
1710
|
+
:return_type => return_type
|
|
1711
|
+
)
|
|
1712
|
+
|
|
1713
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
|
1714
|
+
if @api_client.config.debugging
|
|
1715
|
+
@api_client.config.logger.debug "API called: VolumeGroupsApi#list_volume_groups\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
1716
|
+
end
|
|
1717
|
+
return data, status_code, headers
|
|
1718
|
+
end
|
|
1719
|
+
|
|
1720
|
+
# Revert a Volume Group
|
|
1721
|
+
# Reverts a Volume Group identified by Volume Group external identifier. This API performs an in-place restore from a specified Volume Group recovery point.
|
|
1722
|
+
# @param ext_id [String] The external identifier of a Volume Group.
|
|
1723
|
+
# @param ntnx_request_id [String] A unique identifier that is associated with each request. The provided value must be opaque and preferably in Universal Unique Identifier (UUID) format. This identifier is also used as an idempotence token for safely retrying requests in case of network errors. All the supported Nutanix API clients add this auto-generated request identifier to each request.
|
|
1724
|
+
# @param volumes_v40_config_revert_spec [VolumesV40ConfigRevertSpec] Specify the Volume Group recovery point ID to which the Volume Group would be reverted.
|
|
1725
|
+
# @param [Hash] opts the optional parameters
|
|
1726
|
+
# @return [RevertVolumeGroup202Response]
|
|
1727
|
+
def revert_volume_group(ext_id, ntnx_request_id, volumes_v40_config_revert_spec, opts = {})
|
|
1728
|
+
data, _status_code, _headers = revert_volume_group_with_http_info(ext_id, ntnx_request_id, volumes_v40_config_revert_spec, opts)
|
|
1729
|
+
data
|
|
1730
|
+
end
|
|
1731
|
+
|
|
1732
|
+
# Revert a Volume Group
|
|
1733
|
+
# Reverts a Volume Group identified by Volume Group external identifier. This API performs an in-place restore from a specified Volume Group recovery point.
|
|
1734
|
+
# @param ext_id [String] The external identifier of a Volume Group.
|
|
1735
|
+
# @param ntnx_request_id [String] A unique identifier that is associated with each request. The provided value must be opaque and preferably in Universal Unique Identifier (UUID) format. This identifier is also used as an idempotence token for safely retrying requests in case of network errors. All the supported Nutanix API clients add this auto-generated request identifier to each request.
|
|
1736
|
+
# @param volumes_v40_config_revert_spec [VolumesV40ConfigRevertSpec] Specify the Volume Group recovery point ID to which the Volume Group would be reverted.
|
|
1737
|
+
# @param [Hash] opts the optional parameters
|
|
1738
|
+
# @return [Array<(RevertVolumeGroup202Response, Integer, Hash)>] RevertVolumeGroup202Response data, response status code and response headers
|
|
1739
|
+
def revert_volume_group_with_http_info(ext_id, ntnx_request_id, volumes_v40_config_revert_spec, opts = {})
|
|
1740
|
+
if @api_client.config.debugging
|
|
1741
|
+
@api_client.config.logger.debug 'Calling API: VolumeGroupsApi.revert_volume_group ...'
|
|
1742
|
+
end
|
|
1743
|
+
# verify the required parameter 'ext_id' is set
|
|
1744
|
+
if @api_client.config.client_side_validation && ext_id.nil?
|
|
1745
|
+
fail ArgumentError, "Missing the required parameter 'ext_id' when calling VolumeGroupsApi.revert_volume_group"
|
|
1746
|
+
end
|
|
1747
|
+
pattern = Regexp.new(/^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$/)
|
|
1748
|
+
if @api_client.config.client_side_validation && ext_id !~ pattern
|
|
1749
|
+
fail ArgumentError, "invalid value for 'ext_id' when calling VolumeGroupsApi.revert_volume_group, must conform to the pattern #{pattern}."
|
|
1750
|
+
end
|
|
1751
|
+
|
|
1752
|
+
# verify the required parameter 'ntnx_request_id' is set
|
|
1753
|
+
if @api_client.config.client_side_validation && ntnx_request_id.nil?
|
|
1754
|
+
fail ArgumentError, "Missing the required parameter 'ntnx_request_id' when calling VolumeGroupsApi.revert_volume_group"
|
|
1755
|
+
end
|
|
1756
|
+
# verify the required parameter 'volumes_v40_config_revert_spec' is set
|
|
1757
|
+
if @api_client.config.client_side_validation && volumes_v40_config_revert_spec.nil?
|
|
1758
|
+
fail ArgumentError, "Missing the required parameter 'volumes_v40_config_revert_spec' when calling VolumeGroupsApi.revert_volume_group"
|
|
1759
|
+
end
|
|
1760
|
+
# resource path
|
|
1761
|
+
local_var_path = '/volumes/v4.0/config/volume-groups/{extId}/$actions/revert'.sub('{' + 'extId' + '}', CGI.escape(ext_id.to_s))
|
|
1762
|
+
|
|
1763
|
+
# query parameters
|
|
1764
|
+
query_params = opts[:query_params] || {}
|
|
1765
|
+
|
|
1766
|
+
# header parameters
|
|
1767
|
+
header_params = opts[:header_params] || {}
|
|
1768
|
+
# HTTP header 'Accept' (if needed)
|
|
1769
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
1770
|
+
# HTTP header 'Content-Type'
|
|
1771
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
|
1772
|
+
if !content_type.nil?
|
|
1773
|
+
header_params['Content-Type'] = content_type
|
|
1774
|
+
end
|
|
1775
|
+
header_params[:'NTNX-Request-Id'] = ntnx_request_id
|
|
1776
|
+
|
|
1777
|
+
# form parameters
|
|
1778
|
+
form_params = opts[:form_params] || {}
|
|
1779
|
+
|
|
1780
|
+
# http body (model)
|
|
1781
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(volumes_v40_config_revert_spec)
|
|
1782
|
+
|
|
1783
|
+
# return_type
|
|
1784
|
+
return_type = opts[:debug_return_type] || 'RevertVolumeGroup202Response'
|
|
1785
|
+
|
|
1786
|
+
# auth_names
|
|
1787
|
+
auth_names = opts[:debug_auth_names] || ['apiKeyAuthScheme', 'basicAuthScheme']
|
|
1788
|
+
|
|
1789
|
+
new_options = opts.merge(
|
|
1790
|
+
:operation => :"VolumeGroupsApi.revert_volume_group",
|
|
1791
|
+
:header_params => header_params,
|
|
1792
|
+
:query_params => query_params,
|
|
1793
|
+
:form_params => form_params,
|
|
1794
|
+
:body => post_body,
|
|
1795
|
+
:auth_names => auth_names,
|
|
1796
|
+
:return_type => return_type
|
|
1797
|
+
)
|
|
1798
|
+
|
|
1799
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
|
1800
|
+
if @api_client.config.debugging
|
|
1801
|
+
@api_client.config.logger.debug "API called: VolumeGroupsApi#revert_volume_group\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
1802
|
+
end
|
|
1803
|
+
return data, status_code, headers
|
|
1804
|
+
end
|
|
1805
|
+
|
|
1806
|
+
# Update a specified Volume Disk
|
|
1807
|
+
# Updates a specific Volume Disk identified by {extId}.
|
|
1808
|
+
# @param volume_group_ext_id [String] The external identifier of a Volume Group.
|
|
1809
|
+
# @param ext_id [String] The external identifier of a Volume Disk.
|
|
1810
|
+
# @param if_match [String] The If-Match request header makes the request conditional. When not provided, the server will respond with an HTTP-428 (Precondition Required) response code indicating that the server requires the request to be conditional. The server will allow the successful completion of PUT and PATCH operations, if the resource matches the ETag value returned to the response of a GET operation. If the conditional does not match, then an HTTP-412 (Precondition Failed) response will be returned.
|
|
1811
|
+
# @param ntnx_request_id [String] A unique identifier that is associated with each request. The provided value must be opaque and preferably in Universal Unique Identifier (UUID) format. This identifier is also used as an idempotence token for safely retrying requests in case of network errors. All the supported Nutanix API clients add this auto-generated request identifier to each request.
|
|
1812
|
+
# @param volumes_v40_config_volume_disk [VolumesV40ConfigVolumeDisk] A model that represents a Volume Disk associated with a Volume Group, supported by a backing file on DSF.
|
|
1813
|
+
# @param [Hash] opts the optional parameters
|
|
1814
|
+
# @return [UpdateVolumeDiskById202Response]
|
|
1815
|
+
def update_volume_disk_by_id(volume_group_ext_id, ext_id, if_match, ntnx_request_id, volumes_v40_config_volume_disk, opts = {})
|
|
1816
|
+
data, _status_code, _headers = update_volume_disk_by_id_with_http_info(volume_group_ext_id, ext_id, if_match, ntnx_request_id, volumes_v40_config_volume_disk, opts)
|
|
1817
|
+
data
|
|
1818
|
+
end
|
|
1819
|
+
|
|
1820
|
+
# Update a specified Volume Disk
|
|
1821
|
+
# Updates a specific Volume Disk identified by {extId}.
|
|
1822
|
+
# @param volume_group_ext_id [String] The external identifier of a Volume Group.
|
|
1823
|
+
# @param ext_id [String] The external identifier of a Volume Disk.
|
|
1824
|
+
# @param if_match [String] The If-Match request header makes the request conditional. When not provided, the server will respond with an HTTP-428 (Precondition Required) response code indicating that the server requires the request to be conditional. The server will allow the successful completion of PUT and PATCH operations, if the resource matches the ETag value returned to the response of a GET operation. If the conditional does not match, then an HTTP-412 (Precondition Failed) response will be returned.
|
|
1825
|
+
# @param ntnx_request_id [String] A unique identifier that is associated with each request. The provided value must be opaque and preferably in Universal Unique Identifier (UUID) format. This identifier is also used as an idempotence token for safely retrying requests in case of network errors. All the supported Nutanix API clients add this auto-generated request identifier to each request.
|
|
1826
|
+
# @param volumes_v40_config_volume_disk [VolumesV40ConfigVolumeDisk] A model that represents a Volume Disk associated with a Volume Group, supported by a backing file on DSF.
|
|
1827
|
+
# @param [Hash] opts the optional parameters
|
|
1828
|
+
# @return [Array<(UpdateVolumeDiskById202Response, Integer, Hash)>] UpdateVolumeDiskById202Response data, response status code and response headers
|
|
1829
|
+
def update_volume_disk_by_id_with_http_info(volume_group_ext_id, ext_id, if_match, ntnx_request_id, volumes_v40_config_volume_disk, opts = {})
|
|
1830
|
+
if @api_client.config.debugging
|
|
1831
|
+
@api_client.config.logger.debug 'Calling API: VolumeGroupsApi.update_volume_disk_by_id ...'
|
|
1832
|
+
end
|
|
1833
|
+
# verify the required parameter 'volume_group_ext_id' is set
|
|
1834
|
+
if @api_client.config.client_side_validation && volume_group_ext_id.nil?
|
|
1835
|
+
fail ArgumentError, "Missing the required parameter 'volume_group_ext_id' when calling VolumeGroupsApi.update_volume_disk_by_id"
|
|
1836
|
+
end
|
|
1837
|
+
pattern = Regexp.new(/^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$/)
|
|
1838
|
+
if @api_client.config.client_side_validation && volume_group_ext_id !~ pattern
|
|
1839
|
+
fail ArgumentError, "invalid value for 'volume_group_ext_id' when calling VolumeGroupsApi.update_volume_disk_by_id, must conform to the pattern #{pattern}."
|
|
1840
|
+
end
|
|
1841
|
+
|
|
1842
|
+
# verify the required parameter 'ext_id' is set
|
|
1843
|
+
if @api_client.config.client_side_validation && ext_id.nil?
|
|
1844
|
+
fail ArgumentError, "Missing the required parameter 'ext_id' when calling VolumeGroupsApi.update_volume_disk_by_id"
|
|
1845
|
+
end
|
|
1846
|
+
pattern = Regexp.new(/^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$/)
|
|
1847
|
+
if @api_client.config.client_side_validation && ext_id !~ pattern
|
|
1848
|
+
fail ArgumentError, "invalid value for 'ext_id' when calling VolumeGroupsApi.update_volume_disk_by_id, must conform to the pattern #{pattern}."
|
|
1849
|
+
end
|
|
1850
|
+
|
|
1851
|
+
# verify the required parameter 'if_match' is set
|
|
1852
|
+
if @api_client.config.client_side_validation && if_match.nil?
|
|
1853
|
+
fail ArgumentError, "Missing the required parameter 'if_match' when calling VolumeGroupsApi.update_volume_disk_by_id"
|
|
1854
|
+
end
|
|
1855
|
+
# verify the required parameter 'ntnx_request_id' is set
|
|
1856
|
+
if @api_client.config.client_side_validation && ntnx_request_id.nil?
|
|
1857
|
+
fail ArgumentError, "Missing the required parameter 'ntnx_request_id' when calling VolumeGroupsApi.update_volume_disk_by_id"
|
|
1858
|
+
end
|
|
1859
|
+
# verify the required parameter 'volumes_v40_config_volume_disk' is set
|
|
1860
|
+
if @api_client.config.client_side_validation && volumes_v40_config_volume_disk.nil?
|
|
1861
|
+
fail ArgumentError, "Missing the required parameter 'volumes_v40_config_volume_disk' when calling VolumeGroupsApi.update_volume_disk_by_id"
|
|
1862
|
+
end
|
|
1863
|
+
# resource path
|
|
1864
|
+
local_var_path = '/volumes/v4.0/config/volume-groups/{volumeGroupExtId}/disks/{extId}'.sub('{' + 'volumeGroupExtId' + '}', CGI.escape(volume_group_ext_id.to_s)).sub('{' + 'extId' + '}', CGI.escape(ext_id.to_s))
|
|
1865
|
+
|
|
1866
|
+
# query parameters
|
|
1867
|
+
query_params = opts[:query_params] || {}
|
|
1868
|
+
|
|
1869
|
+
# header parameters
|
|
1870
|
+
header_params = opts[:header_params] || {}
|
|
1871
|
+
# HTTP header 'Accept' (if needed)
|
|
1872
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
1873
|
+
# HTTP header 'Content-Type'
|
|
1874
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
|
1875
|
+
if !content_type.nil?
|
|
1876
|
+
header_params['Content-Type'] = content_type
|
|
1877
|
+
end
|
|
1878
|
+
header_params[:'If-Match'] = if_match
|
|
1879
|
+
header_params[:'NTNX-Request-Id'] = ntnx_request_id
|
|
1880
|
+
|
|
1881
|
+
# form parameters
|
|
1882
|
+
form_params = opts[:form_params] || {}
|
|
1883
|
+
|
|
1884
|
+
# http body (model)
|
|
1885
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(volumes_v40_config_volume_disk)
|
|
1886
|
+
|
|
1887
|
+
# return_type
|
|
1888
|
+
return_type = opts[:debug_return_type] || 'UpdateVolumeDiskById202Response'
|
|
1889
|
+
|
|
1890
|
+
# auth_names
|
|
1891
|
+
auth_names = opts[:debug_auth_names] || ['apiKeyAuthScheme', 'basicAuthScheme']
|
|
1892
|
+
|
|
1893
|
+
new_options = opts.merge(
|
|
1894
|
+
:operation => :"VolumeGroupsApi.update_volume_disk_by_id",
|
|
1895
|
+
:header_params => header_params,
|
|
1896
|
+
:query_params => query_params,
|
|
1897
|
+
:form_params => form_params,
|
|
1898
|
+
:body => post_body,
|
|
1899
|
+
:auth_names => auth_names,
|
|
1900
|
+
:return_type => return_type
|
|
1901
|
+
)
|
|
1902
|
+
|
|
1903
|
+
data, status_code, headers = @api_client.call_api(:PUT, local_var_path, new_options)
|
|
1904
|
+
if @api_client.config.debugging
|
|
1905
|
+
@api_client.config.logger.debug "API called: VolumeGroupsApi#update_volume_disk_by_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
1906
|
+
end
|
|
1907
|
+
return data, status_code, headers
|
|
1908
|
+
end
|
|
1909
|
+
|
|
1910
|
+
# Update details of a specified Volume Group
|
|
1911
|
+
# Updates details of a specific Volume Group identified by {extId}.
|
|
1912
|
+
# @param ext_id [String] The external identifier of a Volume Group.
|
|
1913
|
+
# @param if_match [String] The If-Match request header makes the request conditional. When not provided, the server will respond with an HTTP-428 (Precondition Required) response code indicating that the server requires the request to be conditional. The server will allow the successful completion of PUT and PATCH operations, if the resource matches the ETag value returned to the response of a GET operation. If the conditional does not match, then an HTTP-412 (Precondition Failed) response will be returned.
|
|
1914
|
+
# @param ntnx_request_id [String] A unique identifier that is associated with each request. The provided value must be opaque and preferably in Universal Unique Identifier (UUID) format. This identifier is also used as an idempotence token for safely retrying requests in case of network errors. All the supported Nutanix API clients add this auto-generated request identifier to each request.
|
|
1915
|
+
# @param volumes_v40_config_volume_group [VolumesV40ConfigVolumeGroup] A model that represents a Volume Group resource.
|
|
1916
|
+
# @param [Hash] opts the optional parameters
|
|
1917
|
+
# @return [UpdateVolumeGroupById202Response]
|
|
1918
|
+
def update_volume_group_by_id(ext_id, if_match, ntnx_request_id, volumes_v40_config_volume_group, opts = {})
|
|
1919
|
+
data, _status_code, _headers = update_volume_group_by_id_with_http_info(ext_id, if_match, ntnx_request_id, volumes_v40_config_volume_group, opts)
|
|
1920
|
+
data
|
|
1921
|
+
end
|
|
1922
|
+
|
|
1923
|
+
# Update details of a specified Volume Group
|
|
1924
|
+
# Updates details of a specific Volume Group identified by {extId}.
|
|
1925
|
+
# @param ext_id [String] The external identifier of a Volume Group.
|
|
1926
|
+
# @param if_match [String] The If-Match request header makes the request conditional. When not provided, the server will respond with an HTTP-428 (Precondition Required) response code indicating that the server requires the request to be conditional. The server will allow the successful completion of PUT and PATCH operations, if the resource matches the ETag value returned to the response of a GET operation. If the conditional does not match, then an HTTP-412 (Precondition Failed) response will be returned.
|
|
1927
|
+
# @param ntnx_request_id [String] A unique identifier that is associated with each request. The provided value must be opaque and preferably in Universal Unique Identifier (UUID) format. This identifier is also used as an idempotence token for safely retrying requests in case of network errors. All the supported Nutanix API clients add this auto-generated request identifier to each request.
|
|
1928
|
+
# @param volumes_v40_config_volume_group [VolumesV40ConfigVolumeGroup] A model that represents a Volume Group resource.
|
|
1929
|
+
# @param [Hash] opts the optional parameters
|
|
1930
|
+
# @return [Array<(UpdateVolumeGroupById202Response, Integer, Hash)>] UpdateVolumeGroupById202Response data, response status code and response headers
|
|
1931
|
+
def update_volume_group_by_id_with_http_info(ext_id, if_match, ntnx_request_id, volumes_v40_config_volume_group, opts = {})
|
|
1932
|
+
if @api_client.config.debugging
|
|
1933
|
+
@api_client.config.logger.debug 'Calling API: VolumeGroupsApi.update_volume_group_by_id ...'
|
|
1934
|
+
end
|
|
1935
|
+
# verify the required parameter 'ext_id' is set
|
|
1936
|
+
if @api_client.config.client_side_validation && ext_id.nil?
|
|
1937
|
+
fail ArgumentError, "Missing the required parameter 'ext_id' when calling VolumeGroupsApi.update_volume_group_by_id"
|
|
1938
|
+
end
|
|
1939
|
+
pattern = Regexp.new(/^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$/)
|
|
1940
|
+
if @api_client.config.client_side_validation && ext_id !~ pattern
|
|
1941
|
+
fail ArgumentError, "invalid value for 'ext_id' when calling VolumeGroupsApi.update_volume_group_by_id, must conform to the pattern #{pattern}."
|
|
1942
|
+
end
|
|
1943
|
+
|
|
1944
|
+
# verify the required parameter 'if_match' is set
|
|
1945
|
+
if @api_client.config.client_side_validation && if_match.nil?
|
|
1946
|
+
fail ArgumentError, "Missing the required parameter 'if_match' when calling VolumeGroupsApi.update_volume_group_by_id"
|
|
1947
|
+
end
|
|
1948
|
+
# verify the required parameter 'ntnx_request_id' is set
|
|
1949
|
+
if @api_client.config.client_side_validation && ntnx_request_id.nil?
|
|
1950
|
+
fail ArgumentError, "Missing the required parameter 'ntnx_request_id' when calling VolumeGroupsApi.update_volume_group_by_id"
|
|
1951
|
+
end
|
|
1952
|
+
# verify the required parameter 'volumes_v40_config_volume_group' is set
|
|
1953
|
+
if @api_client.config.client_side_validation && volumes_v40_config_volume_group.nil?
|
|
1954
|
+
fail ArgumentError, "Missing the required parameter 'volumes_v40_config_volume_group' when calling VolumeGroupsApi.update_volume_group_by_id"
|
|
1955
|
+
end
|
|
1956
|
+
# resource path
|
|
1957
|
+
local_var_path = '/volumes/v4.0/config/volume-groups/{extId}'.sub('{' + 'extId' + '}', CGI.escape(ext_id.to_s))
|
|
1958
|
+
|
|
1959
|
+
# query parameters
|
|
1960
|
+
query_params = opts[:query_params] || {}
|
|
1961
|
+
|
|
1962
|
+
# header parameters
|
|
1963
|
+
header_params = opts[:header_params] || {}
|
|
1964
|
+
# HTTP header 'Accept' (if needed)
|
|
1965
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
1966
|
+
# HTTP header 'Content-Type'
|
|
1967
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
|
1968
|
+
if !content_type.nil?
|
|
1969
|
+
header_params['Content-Type'] = content_type
|
|
1970
|
+
end
|
|
1971
|
+
header_params[:'If-Match'] = if_match
|
|
1972
|
+
header_params[:'NTNX-Request-Id'] = ntnx_request_id
|
|
1973
|
+
|
|
1974
|
+
# form parameters
|
|
1975
|
+
form_params = opts[:form_params] || {}
|
|
1976
|
+
|
|
1977
|
+
# http body (model)
|
|
1978
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(volumes_v40_config_volume_group)
|
|
1979
|
+
|
|
1980
|
+
# return_type
|
|
1981
|
+
return_type = opts[:debug_return_type] || 'UpdateVolumeGroupById202Response'
|
|
1982
|
+
|
|
1983
|
+
# auth_names
|
|
1984
|
+
auth_names = opts[:debug_auth_names] || ['apiKeyAuthScheme', 'basicAuthScheme']
|
|
1985
|
+
|
|
1986
|
+
new_options = opts.merge(
|
|
1987
|
+
:operation => :"VolumeGroupsApi.update_volume_group_by_id",
|
|
1988
|
+
:header_params => header_params,
|
|
1989
|
+
:query_params => query_params,
|
|
1990
|
+
:form_params => form_params,
|
|
1991
|
+
:body => post_body,
|
|
1992
|
+
:auth_names => auth_names,
|
|
1993
|
+
:return_type => return_type
|
|
1994
|
+
)
|
|
1995
|
+
|
|
1996
|
+
data, status_code, headers = @api_client.call_api(:PUT, local_var_path, new_options)
|
|
1997
|
+
if @api_client.config.debugging
|
|
1998
|
+
@api_client.config.logger.debug "API called: VolumeGroupsApi#update_volume_group_by_id\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
1999
|
+
end
|
|
2000
|
+
return data, status_code, headers
|
|
2001
|
+
end
|
|
2002
|
+
end
|
|
2003
|
+
end
|