Bug 4051 - How to get StepExecution
How to get StepExecution
Status: CLOSED FIXED
Product: jbatch
Classification: Unclassified
Component: source
1
PC Linux
: P5 enhancement
: ---
Assigned To: cvignola
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2012-08-20 15:34 UTC by htavarez
Modified: 2013-01-16 23:09 UTC (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description htavarez 2012-08-20 15:34:02 UTC
The JobOperator provides a method getStepExecution(jobExecutionId, stepExecutionId) but how do we get the stepExecutionId?  

In fig.X under 1.2 Step, It is implied that a jobExecution has many stepExecutions, but how do we get all the steps executed for a given job execution?
Comment 1 cvignola 2012-10-05 21:44:11 UTC
Looks like we need to add a method for that.
Comment 2 mminella 2012-12-03 15:42:23 UTC
Currently the spec does not have a way to get a StepExecution from the JobExecution it's related to.  Do we want to fix this issue by correcting that instead or just adding a method to the JobOperator?  Spring Batch handles it by allowing the user to get the StepExecutions from the JobExecution (http://static.springsource.org/spring-batch/apidocs/org/springframework/batch/core/JobExecution.html#getStepExecutions()).
Comment 3 cvignola 2013-01-16 17:26:56 UTC
The following method was added to JobOperator:

	List<StepExecution> getStepExecutions(long executionId) throws NoSuchJobExecutionException;