Java Reference
In-Depth Information
The batch.xml configuration file
The batch.xml file is an XML file that contains the batch artifacts of the batch ap-
plication. It establishes a correspondence between the batch artifact implementation
and the reference name that is used in the Job XML file. The batch.xml file must
be stored in the META-INF directory for a portable application. The following code
gives us the contents of the batch.xml file for the inscription-validator-
Job Job shown in the preceding code.
The following code is an example of batch.xml :
<batch-artifacts xmlns="
<ref id="InscriptionReader"
<ref id="StudentNotifier"
<ref id="InscriptionProcessor"
The JobOperator instance is accessible through the getJobOperator() method
of the BatchRuntime class. It provides a set of operations to manage ( start ,
stop , restart and so on) a job and access JobRepository ( getJobNames ,
getJobInstances , getStepExecutions , and so on). The following code shows
how to start the inscription-validator-Job Job shown earlier without any
specific property. It is important to note that the inscriptionJob value that is spe-
cified in the JobOperator.start command is the name of the Job XML file (not
Search WWH ::

Custom Search