getJobs

Back to index

Summary

Retrieve all jobs.
If you use sortKey or sortOrder, you must use both arguments together. You can use firstResult and maxResults together or separately to select a limited sublist of jobs for the result set.
firstResult
Integeroptional
Result pagination: the first row to return.
maxResults
Integeroptional
Result pagination: the number of rows to return.
sortKey
Stringoptional
How to sort the results.
sortOrder
Stringoptional
Specifies the order to sort the results.
Possible values: "ascending", "descending"
status
Stringoptional
Filter jobs by this status.

Usage

Perl

$cmdr->getJobs( # optionals );

ectool

ectool getJobs \ # optionals

Examples

Perl

How do I get the first 10 jobs (index 0-9)?

$cmdr->getJobs({maxResults=>10});

How do I get the next 10 jobs (index 10-19)?

$cmdr->getJobs({firstResult=>10, maxResults=>10});

How do I get the most recent job by start time?

$cmdr->getJobs({sortKey=>'start', sortOrder=>'descending', maxResults=>1});

ectool

How do I get the first 10 jobs (index 0-9)?

ectool getJobs --maxResults 10

How do I get the next 10 jobs (index 10-19)?

ectool getJobs --firstResult 10 --maxResults 10

How do I get the most recent job by start time?

ectool getJobs --sortKey start --sortOrder descending --maxResults 1