Package com.ibm.jbatch.tck.spi
Interface JobExecutionWaiter
public interface JobExecutionWaiter
Waiter to wait for a JobExecution to reach a "final" state, (i.e. to block until it does).
-
Method Summary
Modifier and TypeMethodDescriptionjakarta.batch.runtime.JobExecution
The waiter instance is associated with an execution id via the factory create method.
-
Method Details
-
awaitTermination
The waiter instance is associated with an execution id via the factory create method.This method blocks and only returns when the JobExecution reaches one of these states, which we refer to here as a 'final' state (By 'state' we mean "batch status"). The Jakarta Batch specification doesn't formally define a set of 'final' states or use this term explicitly, so we list here what we consider to be the 'final' states for the TCK purposes.
Final states:
- ABANDONED
- COMPLETED
- FAILED
- STOPPED
(This seems like an obvious, uncontroversial interpretation):
- Returns:
- JobExecution instance (based on JobExecution specified in factory create method).
- Throws:
JobExecutionTimeoutException
- Thrown when JobExecution hasn't reached final state after the timeout specified in the factory create method.- See Also:
-