vCloud API Programming Guide
26 VMware, Inc.
<Task status="running" startTime="2010-06-25T08:00:55.402-07:00" operation="Creating
Virtual Application Linux FTP server(7)"
expiryTime="2010-09-23T08:00:55.402-07:00"
type="application/vnd.vmware.vcloud.task+xml"
href="http://vcloud.example.com/api/v1.0/task/1awvdrn82atz7yzsdey">
<Owner type="application/vnd.vmware.vcloud.vApp+xml" name="LinuxFtpServer"
href="http://vcloud.example.com/vApp/vapp-7"/>
</Task>
</Tasks>
</VApp>
Theî ±responseî ±toî ±theî ±instantiationî ±requestî ±isî ±aî ±sparselyî ±populatedî ±vAppî ±body,î ±whichî ±includesî ±theî ±followingî ±
information:
ïź Theî ±statusî ±ofî ±theî ±vApp.î ±Theî ±statusî ±valueî ±0î ±indicatesî ±thatî ±theî ±vAppî ±isî ±unresolved,î ±becauseî ±instantiationî ±
hasî ±notî ±completed.
ïź Theî ±nameî ±ofî ±theî ±vApp,î ±asî ±suppliedî ±inî ±theî ±request
ïź Theî ±vAppî ±URL,î ±shownî ±inî ±theî ±hrefî ±attributeî ±ofî ±theî ±VAppî ±body
ïź Aî ±taskî ±createdî ±toî ±trackî ±theî ±instantiation.î ±Theî ±Taskî ±elementî ±hasî ±anî ±operationî ±attributeî ±thatî ±describesî ±whatî ±
isî ±happening,î ±andî ±containsî ±anî ±Ownerî ±elementî ±thatî ±isî ±aî ±referenceî ±theî ±vAppî ±beingî ±created.î ±Forî ±moreî ±
information,î ±seeî ±âTaskâî ±onî ±page 168.
Deploying and Powering On the vApp
Afterî ±theî ±instantiationî ±taskî ±completes,î ±theî ±templateî ±hasî ±beenî ±transformedî ±intoî ±aî ±vApp.î ±Theî ±vAppî ±bodyî ±noî ±
longerî ±includesî ±aî ±Tasksî ±element,î ±andî ±itî ±nowî ±includesî ±aî ±numberî ±ofî ±Linkî ±elementsî ±thatî ±youî ±canî ±useî ±toî ±deployî ±
andî ±operateî ±theî ±vApp.î ±Example 2â7î ±showsî ±aî ±requestî ±andî ±responseî ±forî ±aî ±deploy
î ±action.î ±Theî ±requestî ±URLî ±isî ±theî ±
rel="deploy"î ±linkî ±returnedî ±inî ±theî ±vAppî ±bodyî ±(seeî ±Example 2â8).î ±Theî ±requestî ±bodyî ±isî ±aî ±DeployVAppParamsî ±
element,î ±whichî ±specifiesî ±deploymentî ±details.
Example 2-7. Deploy and Power On a vApp
Request:
POST http://vcloud.example.com/api/v1.0/vApp/vapp-7/action/deploy
Content-type: application/vnd.vmware.vcloud.deployVAppParams+xml
...
<DeployVAppParams powerOn="true" deploymentLeaseSeconds="2592000"
xmlns="http://www.vmware.com/vcloud/v1"/>
Response:
202 Accepted
<Task xmlns="http://www.vmware.com/vcloud/v1" status="running"
startTime="2010-06-25T11:15:55.558-07:00" operation="Starting Virtual Application
Linux FTP server(7)" expiryTime="2010-09-23T08:00:55.402-07:00"
type="application/vnd.vmware.vcloud.task+xml"
href="http://vcloud.example.com/api/v1.0/task/i9h1djqzsyllf0zvdy" ...>
<Owner type="application/vnd.vmware.vcloud.vApp+xml" name="LinuxFtpServer"
href="http://vcloud.example.com/vApp/vapp-7"/>
</Task>
Becauseî ±deploymentî ±isî ±aî ±longârunningî ±operationî ±thatî ±canî ±failî ±forî ±aî ±varietyî ±ofî ±reasonsî ±(inabilityî ±ofî ±theî ±vDCî ±toî ±
satisfyî ±theî ±vAppâsî ±resourceî ±requirements,î ±forî ±example),î ±theî ±responseî ±isî ±aî ±Task.
N
OTEî ±î ±î ±Aî ±vAppî ±templateî ±mightî ±includeî ±aî ±licenseî ±agreementî ±orî ±otherî ±termsî ±thatî ±youî ±mustî ±acceptî ±beforeî ±youî ±
canî ±createî ±aî ±vAppî ±fromî ±it.î ±Inî ±thisî ±example,î ±theî ±templateî ±containsî ±noî ±suchî ±terms.î ±Ifî ±itî ±did,î ±theî ±requestî ±wouldî ±
failî ±ifî ±itî ±didî ±notî ±includeî ±anî ±AllEULAsAcceptedî ±element,î ±asî ±shownî ±inî ±
Example 5â1î ±onî ±page 63.