OPEN - issue BATCH-364: StepScope responsibilities can be assumed by Step (not ApplicationContext)
http://jira.springframework.org/browse/BATCH-364 restart sample was failing because of wrong manipulation of version in step execution
This commit is contained in:
@@ -75,17 +75,6 @@ public class Entity implements Serializable {
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
protected void decrementVersion() {
|
||||
if (version == null || version.intValue()==0) {
|
||||
version = new Integer(0);
|
||||
} else {
|
||||
version = new Integer(version.intValue() - 1);
|
||||
}
|
||||
}
|
||||
|
||||
// @Override
|
||||
public String toString() {
|
||||
return ClassUtils.getShortName(getClass()) + ": id=" + getId();
|
||||
|
||||
@@ -357,7 +357,6 @@ public class StepExecution extends Entity {
|
||||
*/
|
||||
public synchronized void rollback() {
|
||||
rollbackCount++;
|
||||
decrementVersion();
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user