use of org.platformlayer.ops.tasks.JobQuery in project platformlayer by platformlayer.
the class JobsCollectionResource method getActiveJobs.
@GET
@Produces({ XML, JSON })
public JobDataList getActiveJobs() throws OpsException {
JobQuery jobQuery = JobQuery.build(getProject(), filterTarget);
List<JobData> jobList = jobRegistry.listRecentJobs(jobQuery);
JobDataList jobs = JobDataList.create();
jobs.jobs = Lists.newArrayList();
for (JobData jobData : jobList) {
jobs.jobs.add(jobData);
}
return jobs;
}
use of org.platformlayer.ops.tasks.JobQuery in project platformlayer by platformlayer.
the class JobsCollectionResource method getExecutions.
@GET
@Path("runs")
@Produces({ XML, JSON })
public JobExecutionList getExecutions() throws OpsException {
JobQuery jobQuery = JobQuery.build(getProject(), filterTarget);
JobExecutionList executions = jobRegistry.listRecentExecutions(jobQuery);
return executions;
}
Aggregations