org.springframework.batch.core.step.tasklet
Interface Tasklet
- All Known Implementing Classes:
- TaskletAdapter
public interface Tasklet
Interface for encapsulating processing logic that is not natural to split
into read-(transform)-write phases, such as invoking a system command or a
stored procedure.
Since the batch framework has no visibility inside the execute()
method, developers should consider implementing StepExecutionListener
and
check the StepExecution.isTerminateOnly()
value for long lasting
processes to enable prompt termination of processing on user request.
It is expected the read-(transform)-write separation will be appropriate for
most cases and developers should implement ItemReader
and
ItemWriter
interfaces then (typically extending or composing provided
implementations).
- Author:
- Lucas Ward, Dave Syer, Robert Kasanicky
Method Summary |
ExitStatus |
execute()
Encapsulates execution logic of Step , which is unnatural to
separate into read-(transform)-write phases. |
execute
ExitStatus execute()
throws Exception
- Encapsulates execution logic of
Step
, which is unnatural to
separate into read-(transform)-write phases.
- Returns:
- ExitStatus indicating success or failure
- Throws:
Exception
- See Also:
ExitStatus
Copyright © 2008 SpringSource. All Rights Reserved.