Package com.vmware.fcd
Class FcdRelocate
- java.lang.Object
-
- com.vmware.connection.ConnectedVimServiceBase
-
- com.vmware.fcd.FcdRelocate
-
@Sample(name="fcd-relocate", description="This sample relocates a virtual storage object.") public class FcdRelocate extends ConnectedVimServiceBaseFcdRelocate This sample relocates a virtual storage object. Parameters: url [required] : url of the web service username [required] : username for the authentication password [required] : password for the authentication vstorageobjectid [required] : Uuid of the vstorageobject datastorename [required] : Name of the datastore which contains the virtual storage object destDatastoreName [required] : Name of destination datastore provisioningtype [optional] : Type of provisioning for the disk [thin | eagerZeroedThick | lazyZeroedThick | virtualMode | physicalMode] hostscsidisk [optional] : Host Scsi disk to clone vStorageObject Command Line: Relocate a virtual storage object. run.bat com.vmware.vm.FcdRelocate --url [webserviceurl] --username [username] --password [password] --vstorageobjectid [vstorageobjectid] --datastorename [datastorename]
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class com.vmware.connection.ConnectedVimServiceBase
ConnectedVimServiceBase.ConnectionException
-
-
Field Summary
-
Fields inherited from class com.vmware.connection.ConnectedVimServiceBase
PROP_ME_NAME, SVC_INST_NAME
-
-
Constructor Summary
Constructors Constructor Description FcdRelocate()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description com.vmware.vim25.VslmRelocateSpecgenerateVslmRelocateSpec(com.vmware.vim25.ManagedObjectReference dsMor, com.vmware.fcd.FcdRelocate.DiskProvisioningTypes provisioningType)This method constructs a VslmCloneSpec for the vStorageObjectvoidinit()voidrun()voidsetDatastoreName(java.lang.String datastoreName)voidsetDestDatastoreName(java.lang.String destDatastoreName)voidsetHostScsiDisk(com.vmware.vim25.HostScsiDisk hostScsiDisk)voidsetProvisioningType(java.lang.String provisioningType)voidsetVStorageObjectId(java.lang.String vStorageObjectId)-
Methods inherited from class com.vmware.connection.ConnectedVimServiceBase
basicConnectionFromConnection, connect, disconnect, getServiceInstanceReference, setConnection, setHostConnection
-
-
-
-
Method Detail
-
init
@Before public void init()
-
setVStorageObjectId
@Option(name="vstorageobjectid", required=true, description="Uuid of the vstorageobject.") public void setVStorageObjectId(java.lang.String vStorageObjectId)- Parameters:
vStorageObjectId- the vStorageObjectId to set
-
setDatastoreName
@Option(name="datastorename", required=true, description="Name of destination datastore for relocation.") public void setDatastoreName(java.lang.String datastoreName)- Parameters:
datastoreName- the datastoreName to set
-
setDestDatastoreName
@Option(name="destdatastoredame", required=true, description="Name of destination datastore.") public void setDestDatastoreName(java.lang.String destDatastoreName)- Parameters:
destDatastoreName- the destDatastoreName to set
-
setProvisioningType
@Option(name="provisioningtype", required=false, description="Provisioning Type of the Disk.\n [thin | eagerZeroedThick | lazyZeroedThick | virtualMode | physicalMode]") public void setProvisioningType(java.lang.String provisioningType)- Parameters:
provisioningType- the provisioningType to set
-
setHostScsiDisk
@Option(name="hostScsiDisk", required=false, description="Uuid of the vstorageobject.") public void setHostScsiDisk(com.vmware.vim25.HostScsiDisk hostScsiDisk)- Parameters:
hostScsiDisk- the hostScsiDisk to set
-
generateVslmRelocateSpec
public com.vmware.vim25.VslmRelocateSpec generateVslmRelocateSpec(com.vmware.vim25.ManagedObjectReference dsMor, com.vmware.fcd.FcdRelocate.DiskProvisioningTypes provisioningType) throws java.lang.IllegalArgumentExceptionThis method constructs a VslmCloneSpec for the vStorageObject- Parameters:
dsMor- The ManagedObjectReferece of the datastoreprovisioningType- The provisioningType of the disk- Returns:
- VslmCreateSpec
- Throws:
java.lang.IllegalArgumentException
-
run
@Action public void run() throws com.vmware.vim25.InvalidPropertyFaultMsg, com.vmware.vim25.RuntimeFaultFaultMsg, com.vmware.vim25.FileFaultFaultMsg, com.vmware.vim25.InvalidDatastoreFaultMsg, com.vmware.vim25.InvalidStateFaultMsg, com.vmware.vim25.NotFoundFaultMsg, com.vmware.vim25.InvalidCollectorVersionFaultMsg- Throws:
com.vmware.vim25.InvalidPropertyFaultMsgcom.vmware.vim25.RuntimeFaultFaultMsgcom.vmware.vim25.FileFaultFaultMsgcom.vmware.vim25.InvalidDatastoreFaultMsgcom.vmware.vim25.InvalidStateFaultMsgcom.vmware.vim25.NotFoundFaultMsgcom.vmware.vim25.InvalidCollectorVersionFaultMsg
-
-