I'm using the Spring Batch (2.2.6.RELEASE) FlowBuilder.SplitBuilder to declare a flow in a Java Config class, which executes 3 subflows in parallel:
@Bean
public SimpleFlow mainFlow() {
return new FlowBuilder<SimpleFlow>("Main Flow")
.start(flow1())
.split(new SimpleAsyncTaskExecutor())
.add(flow2(), flow3())
.build();
}
This syntax comes from spring-batch FlowBuilder.SplitBuilder javadoc.
But then, flow1 is never executed; only flow2 and flow3 are executed.
It looks like a bug to me... What do you think?
A junit test can be found in class ParallelFlowsJobConfigTest on this github repository: https://github.com/galak75/spring-batch-labs