Oh yeah, we didn't see that class. It is probably a better approach. We are using the same class in order to simplify the way the batch is started (currently we can run our batch with:
and that is something we would like to keep. (there can only be defined one Main class in the manifest.mf file, right?)
java -jar my-batch.jar
so to start a one-time job we are doing
(We are forcing the op. to add two parameters just for possible extensibility in the future).
java -DfastRun=true -DjobName=someJob -jar -my-batch.jar