RESOLVED - issue BATCH-1437: Support for CallbackPreferringPlatformTransactionManager (and for native TX in WAS)
Removed FatalException as well, since it isn't needed any more - the fatal condition can be detected in a TX synchronization.
This commit is contained in:
@@ -50,7 +50,7 @@ public class ChunkElementParserTests {
|
||||
public void testInheritSkippable() throws Exception {
|
||||
Map<Class<? extends Throwable>, Boolean> skippable = getExceptionClasses("s1",
|
||||
chunkElementParentAttributeParserTestsContext);
|
||||
assertEquals(12, skippable.size());
|
||||
assertEquals(11, skippable.size());
|
||||
containsClassified(skippable, NullPointerException.class, true);
|
||||
containsClassified(skippable, ArithmeticException.class, true);
|
||||
containsClassified(skippable, CannotAcquireLockException.class, false);
|
||||
@@ -61,7 +61,7 @@ public class ChunkElementParserTests {
|
||||
public void testInheritSkippableWithNoMerge() throws Exception {
|
||||
Map<Class<? extends Throwable>, Boolean> skippable = getExceptionClasses("s2",
|
||||
chunkElementParentAttributeParserTestsContext);
|
||||
assertEquals(10, skippable.size());
|
||||
assertEquals(9, skippable.size());
|
||||
containsClassified(skippable, NullPointerException.class, true);
|
||||
assertFalse(skippable.containsKey(ArithmeticException.class));
|
||||
containsClassified(skippable, CannotAcquireLockException.class, false);
|
||||
|
||||
@@ -21,7 +21,6 @@ import org.springframework.batch.core.repository.JobExecutionAlreadyRunningExcep
|
||||
import org.springframework.batch.core.repository.JobInstanceAlreadyCompleteException;
|
||||
import org.springframework.batch.core.repository.JobRepository;
|
||||
import org.springframework.batch.core.repository.JobRestartException;
|
||||
import org.springframework.batch.core.step.FatalException;
|
||||
import org.springframework.beans.BeansException;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.context.ApplicationContext;
|
||||
@@ -122,15 +121,6 @@ public class FaultTolerantExceptionClassesTests implements ApplicationContextAwa
|
||||
assertEquals("[]", writer.getCommitted().toString());
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testInternalFatalChecked() throws Exception {
|
||||
writer.setExceptionType(FatalException.class);
|
||||
StepExecution stepExecution = launchStep("skippableFatalStep");
|
||||
assertEquals(BatchStatus.UNKNOWN, stepExecution.getStatus());
|
||||
assertEquals("[1, 2, 3]", writer.getWritten().toString());
|
||||
assertEquals("[]", writer.getCommitted().toString());
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testSkippableChecked() throws Exception {
|
||||
writer.setExceptionType(SkippableException.class);
|
||||
|
||||
@@ -371,8 +371,7 @@ public class TaskletStepTests {
|
||||
|
||||
step.execute(stepExecution);
|
||||
Throwable e = stepExecution.getFailureExceptions().get(0);
|
||||
assertEquals("Fatal failure detected", e.getMessage());
|
||||
assertEquals("foo", e.getCause().getMessage());
|
||||
assertEquals("foo", e.getMessage());
|
||||
assertEquals(BatchStatus.UNKNOWN, stepExecution.getStatus());
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user