Retrieve list of jobs
/api/v1/job/list?vdc=controller-name
Name of the target virtual data center
synchronous
GET
Retrieve list of jobs
GET http://192.168.123.200/api/v1/job/list?vdc=mygrid
<jobs> <job>03a3b9c0-2009-4408-a6a4-a8a9d57cc225</job> </jobs> <jobs> <job>2287a615-e63c-4110-bc46-576d17fe9d12</job> </jobs> . . .
{
"jobs" : [
{
"job" : "03a3b9c0-2009-4408-a6a4-a8a9d57cc225"
},
{
"job" : "2287a615-e63c-4110-bc46-576d17fe9d12"
},
.
.
.
]
}
Retrieve information for a job
/api/v1/job/info?job=job-id&console=console&vdc=controller-name
Job ID
The values specify additional output included in the response:
Console=0 gives no additional information. Default: 0
console=1 gives stdout
console=2 gives stderr
console=3 gives stdout and stderr
When set to 1, the job is not deleted from the list of completed jobs. By default, when a job/info query is executed against a completed job, it is removed from the job list.
Default: 0
Name of the target virtual data center
synchronous
GET
Retrieve information for job=c4830d52-b523-4a3f-933a-34c9c5a4766a
GET http://192.168.123.200/api/v1/job/info?job=c4830d52-b523-4a3f-933a-34c9c5a4766a&vdc=mygrid
<opt> <completed>1</completed> <status>0</status> <time_completed>1271810563</time_completed> <time_started>1271810562</time_started> </opt>
{
"status" : "0\n",
"time_started" : "1271810371",
"time_completed" : "1271810372",
"completed" : 1
}
Entity job c4830d52-b523-4a3f-933a-34c9c5a4766a not found - ID for the job specified is invalid or job is complete.
|
Copyright © 2012 CA.
All rights reserved.
|
|