Bug 4288

Summary: What does Batchlet.stop apply to?
Product: jbatch Reporter: mminella
Component: sourceAssignee: cvignola
Severity: normal CC: issues
Priority: P5    
Version: 1   
Target Milestone: ---   
Hardware: All   
OS: All   

Description mminella 2012-11-09 22:50:34 UTC
Batchlet.stop is an instance method, so it is presumed that calling it would stop the execution of that instance (not all instances in a multithreaded scenario) but it is not clear either way from the spec.
Comment 1 cvignola 2012-11-17 19:29:15 UTC
Stop is called by the batch runtime. 

Section 8.11 of the spec states:

"Batchlet Step

The job and step batch status is marked STOPPING. The batch runtime invokes the batchlet's stop method, if defined.  The batch runtime then interrupts the batchlet thread, which results in java.lang.InterruptedException. The job and step batch status is marked STOPPED."

Let me know if you still think the spec is unclear.