我正在研究 SpringBatch CommandLineJobRunner。我想从单个作业运行多个作业。这是我的代码。我的代码没问题,但如果 CommandLineJobRunner.presetSystemExiter( new SystemExiter() 不包括它只运行 1 个作业并且不能提供多个作业,我不理解。所以请解释一下这是如何工作的。
CommandLineJobRunner.presetSystemExiter( new SystemExiter()
{
public void exit( int status )
{
}
});
String[] params1 = { jobConfig1, jobID1, "runId=" + new Date().getTime() };
CommandLineJobRunner.main(params1);
String[] params2 = { jobConfig2, jobID2, "runId=" + new Date().getTime() };
CommandLineJobRunner.main(params2);
非常感谢。