【发布时间】:2020-05-05 22:13:12
【问题描述】:
我的批处理作业配置如下
@Bean("MyJob")
public Job umpInpatientCensusRptBatchJob(...) throws IOException {
return jobBuilderFactory.get( "MyJob" )
.incrementer( new RunIdIncrementer() )
.start( Step0 ).on( COMPLETE ).end()
.from( Step0 ).on( CONTINUE )
.to( Step1 )
.next( Step2 )
.next( Step3 )
.end()
.build();
}
其中步骤 0、1 和 3 是 tasklet。我的工作正在通过消息 Job: [FlowJob: [name=MyJob]] completed with the following parameters 完成。然而,它并没有退出——它挂在那里。当我在 IntelliJ 上本地运行它时,我必须手动退出该工作。
我没有实现任何异步。每个 tasklet 在完成时也会显式返回 FINISHED 状态。
【问题讨论】:
标签: spring-batch spring-batch-tasklet