问题
I have developed a java batch program using the JSR352 implementation (javax.batch.api.*)
What is the best way to run this java batch program in a Java SE environment ?
ps: We can deploy this program to a JEE server having JSR352 implementation but, we are looking for methods to run in a Java SE environment, where i can run the java program as a simple console application.
ps2: i have the javaee-api-7.0.jar in my project classpath.
回答1:
This approach worked. I was able to run a java batch in Java SE but, not sure how optimized this JSR352 implementation could be relied for Production grade jobs & data volume.
http://www.mastertheboss.com/javaee/batch-api/running-batch-jobs-in-j2se-applications
and
Standalone example on jberet (jsr352)
来源:https://stackoverflow.com/questions/46239289/how-to-run-java-batch-jsr352-in-java-se-environment