public class SimpleTaskExplorer extends Object implements TaskExplorer
Constructor and Description |
---|
SimpleTaskExplorer(TaskExecutionDaoFactoryBean taskExecutionDaoFactoryBean) |
Modifier and Type | Method and Description |
---|---|
org.springframework.data.domain.Page<TaskExecution> |
findAll(org.springframework.data.domain.Pageable pageable)
Retrieves all the task executions within the pageable constraints sorted by
start date descending, taskExecution id descending.
|
org.springframework.data.domain.Page<TaskExecution> |
findRunningTaskExecutions(String taskName,
org.springframework.data.domain.Pageable pageable)
Retrieve a collection of taskExecutions that have the task name provided.
|
org.springframework.data.domain.Page<TaskExecution> |
findTaskExecutionsByName(String taskName,
org.springframework.data.domain.Pageable pageable)
Get a collection/page of executions
|
Set<Long> |
getJobExecutionIdsByTaskExecutionId(long taskExecutionId)
Returns a Set of JobExecution ids for the jobs that were executed within the scope
of the requested task.
|
TaskExecution |
getTaskExecution(long executionId)
Retrieve a
TaskExecution by its id. |
long |
getTaskExecutionCount()
Retrieves current number of task executions.
|
long |
getTaskExecutionCountByTaskName(String taskName)
Get number of executions for a taskName.
|
Long |
getTaskExecutionIdByJobExecutionId(long jobExecutionId)
Returns the id of the TaskExecution that the requested Spring Batch job execution
was executed within the context of.
|
List<String> |
getTaskNames()
Retrieve a list of available task names.
|
public SimpleTaskExplorer(TaskExecutionDaoFactoryBean taskExecutionDaoFactoryBean)
public TaskExecution getTaskExecution(long executionId)
TaskExplorer
TaskExecution
by its id.getTaskExecution
in interface TaskExplorer
executionId
- the task execution idTaskExecution
with this id, or null if not foundpublic org.springframework.data.domain.Page<TaskExecution> findRunningTaskExecutions(String taskName, org.springframework.data.domain.Pageable pageable)
TaskExplorer
findRunningTaskExecutions
in interface TaskExplorer
taskName
- the name of the taskpageable
- the constraints for the searchpublic List<String> getTaskNames()
TaskExplorer
getTaskNames
in interface TaskExplorer
public long getTaskExecutionCountByTaskName(String taskName)
TaskExplorer
getTaskExecutionCountByTaskName
in interface TaskExplorer
taskName
- the name of the task to be searchedpublic long getTaskExecutionCount()
TaskExplorer
getTaskExecutionCount
in interface TaskExplorer
public org.springframework.data.domain.Page<TaskExecution> findTaskExecutionsByName(String taskName, org.springframework.data.domain.Pageable pageable)
TaskExplorer
findTaskExecutionsByName
in interface TaskExplorer
taskName
- the name of the task to be searchedpageable
- the constraints for the searchpublic org.springframework.data.domain.Page<TaskExecution> findAll(org.springframework.data.domain.Pageable pageable)
TaskExplorer
findAll
in interface TaskExplorer
pageable
- the constraints for the searchpublic Long getTaskExecutionIdByJobExecutionId(long jobExecutionId)
TaskExplorer
getTaskExecutionIdByJobExecutionId
in interface TaskExplorer
jobExecutionId
- the id of the JobExecutionTaskExecution
public Set<Long> getJobExecutionIdsByTaskExecutionId(long taskExecutionId)
TaskExplorer
getJobExecutionIdsByTaskExecutionId
in interface TaskExplorer
taskExecutionId
- id of the TaskExecution
Set
of the ids of the job executions executed within the task.Copyright © 2016 Pivotal Software, Inc.. All rights reserved.