Class TaskBatchEventListenerBeanPostProcessor
java.lang.Object
org.springframework.cloud.task.batch.listener.support.TaskBatchEventListenerBeanPostProcessor
- All Implemented Interfaces:
org.springframework.beans.factory.config.BeanPostProcessor
@ImportRuntimeHints(org.springframework.cloud.task.batch.listener.support.TaskBatchEventListenerBeanPostProcessor.RuntimeHint.class)
public class TaskBatchEventListenerBeanPostProcessor
extends Object
implements org.springframework.beans.factory.config.BeanPostProcessor
Attaches the listeners to the job and its steps. Based on the type of bean that is
being processed will determine what listener is attached.
- If the bean is of type AbstractJob then the JobExecutionListener is registered with this bean.
- If the bean is of type AbstractStep then the StepExecutionListener is registered with this bean.
- If the bean is of type TaskletStep then the ChunkEventListener is registered with this bean.
- If the tasklet for the TaskletStep is of type ChunkOrientedTasklet the following listeners will be registered.
-
- ItemReadListener with the ChunkProvider.
- ItemProcessListener with the ChunkProcessor.
- ItemWriteEventsListener with the ChunkProcessor.
- SkipEventsListener with the ChunkProcessor.
- Author:
- Michael Minella, Glenn Renfro
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionpostProcessAfterInitialization
(Object bean, String beanName) postProcessBeforeInitialization
(Object bean, String beanName)
-
Constructor Details
-
TaskBatchEventListenerBeanPostProcessor
public TaskBatchEventListenerBeanPostProcessor()
-
-
Method Details
-
postProcessBeforeInitialization
public Object postProcessBeforeInitialization(Object bean, String beanName) throws org.springframework.beans.BeansException - Specified by:
postProcessBeforeInitialization
in interfaceorg.springframework.beans.factory.config.BeanPostProcessor
- Throws:
org.springframework.beans.BeansException
-
postProcessAfterInitialization
public Object postProcessAfterInitialization(Object bean, String beanName) throws org.springframework.beans.BeansException - Specified by:
postProcessAfterInitialization
in interfaceorg.springframework.beans.factory.config.BeanPostProcessor
- Throws:
org.springframework.beans.BeansException
-