Class TaskBatchExecutionListener
java.lang.Object
org.springframework.cloud.task.batch.listener.TaskBatchExecutionListener
- All Implemented Interfaces:
org.springframework.batch.core.JobExecutionListener
,org.springframework.core.Ordered
public class TaskBatchExecutionListener
extends Object
implements org.springframework.batch.core.JobExecutionListener, org.springframework.core.Ordered
Responsible for storing the relationship between a Spring Batch job and the Spring
Cloud task it was executed within.
- Author:
- Michael Minella
-
Field Summary
Fields inherited from interface org.springframework.core.Ordered
HIGHEST_PRECEDENCE, LOWEST_PRECEDENCE
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
beforeJob
(org.springframework.batch.core.JobExecution jobExecution) int
getOrder()
void
onTaskStartup
(TaskExecution taskExecution) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.springframework.batch.core.JobExecutionListener
afterJob
-
Constructor Details
-
TaskBatchExecutionListener
- Parameters:
taskBatchDao
- dao used to persist the relationship. Must not be null
-
-
Method Details
-
onTaskStartup
-
beforeJob
public void beforeJob(org.springframework.batch.core.JobExecution jobExecution) - Specified by:
beforeJob
in interfaceorg.springframework.batch.core.JobExecutionListener
-
getOrder
public int getOrder()- Specified by:
getOrder
in interfaceorg.springframework.core.Ordered
-