[jboss-svn-commits] JBL Code SVN: r37648 - labs/jbosstm/branches/JBOSSTS_4_15_0_Final/atsintegration/tests/classes/com/arjuna/ats/jta/distributed.
jboss-svn-commits at lists.jboss.org
jboss-svn-commits at lists.jboss.org
Fri Oct 21 05:51:53 EDT 2011
Author: tomjenkinson
Date: 2011-10-21 05:51:53 -0400 (Fri, 21 Oct 2011)
New Revision: 37648
Modified:
labs/jbosstm/branches/JBOSSTS_4_15_0_Final/atsintegration/tests/classes/com/arjuna/ats/jta/distributed/SimpleIsolatedServers.java
Log:
JBTM-895 added more documentation for the tests
Modified: labs/jbosstm/branches/JBOSSTS_4_15_0_Final/atsintegration/tests/classes/com/arjuna/ats/jta/distributed/SimpleIsolatedServers.java
===================================================================
--- labs/jbosstm/branches/JBOSSTS_4_15_0_Final/atsintegration/tests/classes/com/arjuna/ats/jta/distributed/SimpleIsolatedServers.java 2011-10-21 08:16:49 UTC (rev 37647)
+++ labs/jbosstm/branches/JBOSSTS_4_15_0_Final/atsintegration/tests/classes/com/arjuna/ats/jta/distributed/SimpleIsolatedServers.java 2011-10-21 09:51:53 UTC (rev 37648)
@@ -101,6 +101,8 @@
}
/**
+ * Ensure that two servers can start up and call recover on the same server
+ *
* The JCA XATerminator call wont allow intermediary calls to
* XATerminator::recover between TMSTARTSCAN and TMENDSCAN. This is fine for
* distributed JTA.
@@ -135,6 +137,10 @@
}
}
+ /**
+ * Ensure that subordinate XA resource orphans created during 2PC can be
+ * recovered
+ */
@Test
@BMScript("leaveorphan")
public void testTwoPhaseXAResourceOrphan() throws Exception {
@@ -213,6 +219,10 @@
}
}
+ /**
+ * Ensure that subordinate XA resource orphans created during 1PC (at root)
+ * can be recovered
+ */
@Test
@BMScript("leaveorphan")
public void testOnePhaseXAResourceOrphan() throws Exception {
@@ -292,6 +302,10 @@
}
}
+ /**
+ * Ensure that subordinate transaction orphans created during 1PC (at root)
+ * can be recovered
+ */
@Test
@BMScript("leave-subordinate-orphan")
public void testOnePhaseSubordinateOrphan() throws Exception {
@@ -365,12 +379,14 @@
}
/**
- * recoverFor (as it is now known) it first greps the logs for any
- * subordinates that are owned by "parentNodeName" then it greps the list of
- * currently running transactions to see if any of them are owned by
- * "parentNodeName" this is covered by testRecoverInflightTransaction
- * basically what can happen is:
+ * Check that if transaction was in flight when a root crashed, when
+ * recovered it can terminate it.
*
+ * recoverFor first greps the logs for any subordinates that are owned by
+ * "parentNodeName" then it greps the list of currently running transactions
+ * to see if any of them are owned by "parentNodeName" this is covered by
+ * testRecoverInflightTransaction basically what can happen is:
+ *
* 1. TM1 starts tx 2. propagate to TM2 3. TM1 crashes 4. we need to
* rollback TM2 as it is now orphaned the detail being that as TM2 hasn't
* prepared we cant just grep the logs at TM2 as there wont be one
@@ -477,6 +493,9 @@
assertTrue(counter.getRollbackCount() == 2);
}
+ /**
+ * Top down recovery of a prepared transaction
+ */
@Test
@BMScript("fail2pc")
public void testRecovery() throws Exception {
More information about the jboss-svn-commits
mailing list