Package org.springframework.batch.core
Interface Step
- All Known Implementing Classes:
AbstractStep
,DelegateStep
,FlowStep
,JobStep
,PartitionStep
,TaskletStep
public interface Step
Batch domain interface representing the configuration of a step. As with a
Job
,
a Step
is meant to explicitly represent the configuration of a step by a
developer but also the ability to execute the step.- Author:
- Dave Syer, Mahmoud Ben Hassine
-
Field Summary
Modifier and TypeFieldDescriptionstatic final String
The key to use when retrieving the batch step type. -
Method Summary
Modifier and TypeMethodDescriptionvoid
execute
(StepExecution stepExecution) Process the step and assign progress and status meta information to theStepExecution
provided.getName()
default int
default boolean
-
Field Details
-
STEP_TYPE_KEY
The key to use when retrieving the batch step type.- See Also:
-
-
Method Details
-
getName
String getName()- Returns:
- the name of this step.
-
isAllowStartIfComplete
default boolean isAllowStartIfComplete()- Returns:
true
if a step that is already marked as complete can be started again. Defaults tofalse
.
-
getStartLimit
default int getStartLimit()- Returns:
- the number of times a step can be (re)started for the same job instance.
Defaults to
Integer.MAX_VALUE
-
execute
Process the step and assign progress and status meta information to theStepExecution
provided. TheStep
is responsible for setting the meta information and also saving it, if required by the implementation.
It is not safe to reuse an instance ofStep
to process multiple concurrent executions.- Parameters:
stepExecution
- an entity representing the step to be executed.- Throws:
JobInterruptedException
- if the step is interrupted externally.
-