Spring batch Spring作业在步骤异常时失败,但我没有';我不想这样

Spring batch Spring作业在步骤异常时失败,但我没有';我不想这样,spring-batch,Spring Batch,所以我有这份工作。它有15个步骤。可以打开或关闭这些步骤,以确定它们是否将运行(基于客户端) 决策器根据是否选中复选框来决定已完成或失败 问题是我无法指定方法本身会发生什么。换句话说,我不能说在失败时,转到tasklet中的步骤3。因此,如果我的任何步骤Tasklet抛出异常,整个作业都会失败。我只希望每一步都失败。这可能吗 <job id="regularEndOfDay" parent="jobParent" xmlns="http://www.springframework.org/

所以我有这份工作。它有15个步骤。可以打开或关闭这些步骤,以确定它们是否将运行(基于客户端)

决策器根据是否选中复选框来决定
已完成
失败

问题是我无法指定方法本身会发生什么。换句话说,我不能说在失败时,转到tasklet中的步骤3。因此,如果我的任何步骤Tasklet抛出异常,整个作业都会失败。我只希望每一步都失败。这可能吗

<job id="regularEndOfDay" parent="jobParent" xmlns="http://www.springframework.org/schema/batch">
<decision id="eodStep01Decider" decider="eodDecider01">
   <next on="COMPLETED" to="eodStep01PrintChartOfAccountsReport"/>
   <next on="FAILED" to="eodStep02Decider"/>
</decision>
<step id="eodStep01PrintChartOfAccountsReport" next="eodStep02Decider">
   <tasklet ref="printChartOfAccountsReportTasklet"/>
</step>
<decision id="eodStep02Decider" decider="eodDecider02">
   <next on="COMPLETED" to="eodStep02PrintListOfEmployeeGoals"/>
   <next on="FAILED" to="eodStep03Decider"/>
</decision>
<step id="eodStep02PrintListOfEmployeeGoals" next="eodStep03Decider">
   <tasklet ref="printListOfEmployeeGoalsTasklet"/>
</step>
...

...

在我的例子中,当我试图修改步骤时,出现了一个错误,如下所示:

<step id="eodStep01PrintChartOfAccountsReport" next="eodStep02Decider">
   <tasklet ref="printChartOfAccountsReportTasklet"/>
   <next on="*" to="eodStep02Decider" />
</step>
是什么给我带来了麻烦。一旦我删除了它,它就让我把
next=“on”
放在步骤中,一切都很好

很抱歉在这件事上浪费了任何人的时间。希望将来会有其他人发现这一点,并对他们有所帮助

next="eodStep02Decider"