Description: Modify(or Update) VM RAM, CPU and HardDisk at a time with specified values using vSphere java API. Input & Steps:: 1) CPU(numCPUs) - Provide num of cpus count,it never exceed host supported num of cpus 2) RAM(ramMB) - Provide ram value in MB, it never exceed host max alloted memory 3) HardDisk(diskCapacityinKB) - Provide harddisk value in KB, it never exceeds harddisk datastore freeDiskSpace. 4) harddiskName - Eg- "Hard disk 2" or "Hard disk 3" Note1:: It is recommended to assign for harddiskName should start from "Hard disk 2",because "Hard disk 1" contains the OS data and sometimes contains snapshots, will not allowed to extend disk. Note2:: For PowerON VM- Before modify RAM/CPU it is mandatory to enable the VM Memory Hot Add & CPU Hot Plug feature and also VM OS supports.
How to run this sample: http://vthinkbeyondvm.com/getting-started-with-yavi-java-opensource-java-sdk-for-vmware-vsphere-step-by-step-guide-for-beginners/