public interface JobLauncher
|Modifier and Type||Method and Description|
Start a job execution for the given
JobExecution run(Job job, JobParameters jobParameters) throws JobExecutionAlreadyRunningException, JobRestartException, JobInstanceAlreadyCompleteException, JobParametersInvalidException
JobParameters. If a
JobExecutionwas able to be created successfully, it will always be returned by this method, regardless of whether or not the execution was successful. If there is a past
JobExecutionwhich has paused, the same
JobExecutionis returned instead of a new one created. A exception will only be thrown if there is a failure to start the job. If the job encounters some error while processing, the JobExecution will be returned, and the status will need to be inspected.
JobExecutionif it returns synchronously. If the implementation is asynchronous, the status might well be unknown.
JobExecutionAlreadyRunningException- if the JobInstance identified by the properties already has an execution running.
java.lang.IllegalArgumentException- if the job or jobInstanceProperties are null.
JobRestartException- if the job has been run before and circumstances that preclude a re-start.
JobInstanceAlreadyCompleteException- if the job has been run before with the same parameters and completed successfully
JobParametersInvalidException- if the parameters are not valid for this job