public class RetryingTransactionHelperTest
extends junit.framework.TestCase
RetryingTransactionHelper,
TransactionService| Constructor and Description |
|---|
RetryingTransactionHelperTest() |
| Modifier and Type | Method and Description |
|---|---|
void |
setUp() |
void |
tearDown() |
void |
testConcurrencyRetryingNoFailure() |
void |
testLostConnectionRecovery() |
void |
testNestedWithoutPropogation()
Checks nesting of two transactions with
requiresNew == true |
void |
testNestedWithoutPropogationConcurrentUntilFailureMySQL()
Checks nesting of two transactions with
requiresNew == true,
but where the two transactions get involved in a concurrency struggle. |
void |
testNestedWithPropogation()
Checks nesting of two transactions with
requiresNew == false |
void |
testNonRetryingFailure()
Checks that a non-retrying exception is passed out and that the transaction is rolled back.
|
void |
testNonRetryingSilentRollback()
Sometimes, exceptions or other states may cause the transaction to be marked for
rollback without an exception being generated.
|
void |
testSetUp() |
void |
testSuccessNoRetry()
Check that it works without complications.
|
void |
testSuccessWithRetry()
Check that the retries happening for simple concurrency exceptions
|
void |
testTimeLimit() |
void |
testUserTransactionStatus()
Check that the transaction state can be fetched in and around the transaction.
|
void |
testZeroAndNegativeRetries() |
countTestCases, createResult, getName, run, run, runBare, runTest, setName, toStringassertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertFalse, assertFalse, assertNotNull, assertNotNull, assertNotSame, assertNotSame, assertNull, assertNull, assertSame, assertSame, assertTrue, assertTrue, fail, fail, failNotEquals, failNotSame, failSame, formatpublic void setUp()
throws java.lang.Exception
setUp in class junit.framework.TestCasejava.lang.Exceptionpublic void tearDown()
throws java.lang.Exception
tearDown in class junit.framework.TestCasejava.lang.Exceptionpublic void testSetUp()
throws java.lang.Exception
java.lang.Exceptionpublic void testSuccessNoRetry()
public void testUserTransactionStatus()
public void testSuccessWithRetry()
public void testNonRetryingFailure()
public void testNonRetryingSilentRollback()
public void testNestedWithPropogation()
requiresNew == falsepublic void testNestedWithoutPropogation()
requiresNew == truepublic void testNestedWithoutPropogationConcurrentUntilFailureMySQL()
throws java.lang.InterruptedException
requiresNew == true,
but where the two transactions get involved in a concurrency struggle.
Note: skip test for non-MySQLjava.lang.InterruptedExceptionpublic void testConcurrencyRetryingNoFailure()
throws java.lang.InterruptedException
java.lang.InterruptedExceptionpublic void testLostConnectionRecovery()
public void testZeroAndNegativeRetries()
public void testTimeLimit()
Copyright © 2005 - 2010 Alfresco Software, Inc. All Rights Reserved.