Incomplete - task 84: Fix samples

Fix rollback tests as well - exception handler too complicated
This commit is contained in:
dsyer
2008-02-26 15:16:02 +00:00
parent ee2c20f568
commit 55e35eac1c
7 changed files with 13 additions and 25 deletions

View File

@@ -195,8 +195,8 @@ public class ItemOrientedStep extends AbstractStep implements InitializingBean {
((RepeatTemplate) chunkOperations).setCompletionPolicy(new SimpleCompletionPolicy(commitInterval));
}
if (this.chunkOperations instanceof RepeatTemplate && exceptionHandler != null) {
((RepeatTemplate) chunkOperations).setExceptionHandler(exceptionHandler);
if (this.stepOperations instanceof RepeatTemplate && exceptionHandler != null) {
((RepeatTemplate) stepOperations).setExceptionHandler(exceptionHandler);
}
}

View File

@@ -355,7 +355,7 @@ public class ItemOrientedStepTests extends TestCase {
public void testApplyConfigurationWithExceptionHandler() throws Exception {
final List list = new ArrayList();
itemOrientedStep.setChunkOperations(new RepeatTemplate() {
itemOrientedStep.setStepOperations(new RepeatTemplate() {
public void setExceptionHandler(ExceptionHandler exceptionHandler) {
list.add(exceptionHandler);
}