Class DefaultStepExecutionAggregator
- java.lang.Object
- org.springframework.batch.core.partition.support.DefaultStepExecutionAggregator
- All Implemented Interfaces:
StepExecutionAggregator
public class DefaultStepExecutionAggregator extends java.lang.Object implements StepExecutionAggregator
Convenience class for aggregating a set ofStepExecution
instances into a single result.- Since:
- 2.1
- Author:
- Dave Syer
Constructor Summary
Constructors Constructor Description DefaultStepExecutionAggregator()
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
aggregate(StepExecution result, java.util.Collection<StepExecution> executions)
Aggregates the input executions into the resultStepExecution
.
Method Detail
aggregate
public void aggregate(StepExecution result, java.util.Collection<StepExecution> executions)
Aggregates the input executions into the resultStepExecution
. The aggregated fields are- status - choosing the highest value using
BatchStatus.max(BatchStatus, BatchStatus)
- exitStatus - using
ExitStatus.and(ExitStatus)
- commitCount, rollbackCount, etc. - by arithmetic sum
- Specified by:
aggregate
in interfaceStepExecutionAggregator
- Parameters:
result
- the result to overwriteexecutions
- the inputs- See Also:
#aggregate(StepExecution, Collection)
- status - choosing the highest value using