RESOLVED - issue BATCH-419: JobListener and StepListener should pass in JobExecution/StepExecution in each method

http://jira.springframework.org/browse/BATCH-419

added the StepExecution argument to StepListener#onErrorInStep method

OPEN - issue BATCH-329: Make "VERSION" meaningful? 
http://jira.springframework.org/browse/BATCH-329

MapStepExecutionDao now handles version similarly to JdbcStepExecutionDao
This commit is contained in:
robokaso
2008-03-06 16:02:22 +00:00
parent db4b121b22
commit 7a57b634c1
13 changed files with 72 additions and 22 deletions

View File

@@ -38,9 +38,10 @@ public interface StepListener extends BatchListener {
* {@link ExitStatus#and(ExitStatus)}.
*
* @param e an exception thrown by the step execution
*
* @return an exit status to be combined with the normal one, or null
*/
ExitStatus onErrorInStep(Throwable e);
ExitStatus onErrorInStep(StepExecution stepExecution, Throwable e);
/**
* Give a listener a chance to modify the exit status from a step. The value

View File

@@ -48,7 +48,7 @@ public class BatchListenerSupport implements StepListener, ChunkListener,
/* (non-Javadoc)
* @see org.springframework.batch.core.domain.StepListener#onErrorInStep(java.lang.Throwable)
*/
public ExitStatus onErrorInStep(Throwable e) {
public ExitStatus onErrorInStep(StepExecution stepExecution, Throwable e) {
return null;
}

View File

@@ -41,7 +41,7 @@ public class StepListenerSupport implements StepListener {
/* (non-Javadoc)
* @see org.springframework.batch.core.domain.StepListener#onError(java.lang.Throwable)
*/
public ExitStatus onErrorInStep(Throwable e) {
public ExitStatus onErrorInStep(StepExecution stepExecution, Throwable e) {
return null;
}
}