[jbossts-issues] [JBoss JIRA] Commented: (JBTM-506) jtax subordinate TransactionImple confuses TwoPhaseOutcome and ActionStatus

Jonathan Halliday (JIRA) jira-events at lists.jboss.org
Thu Mar 5 12:35:23 EST 2009


    [ https://jira.jboss.org/jira/browse/JBTM-506?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12455680#action_12455680 ] 

Jonathan Halliday commented on JBTM-506:
----------------------------------------

I've checked in the subordinate tx refactoring changes (JBTM-505) even though they still need a bit of polish, since they include the ability to run the Subordinate tx unit tests in jts mode, which will be useful for fixing this.  For now the tests are disabled to avoid breaking the build. Edit ArjunaJTS/jtax/build.xml and remove the XX from

<include  name="**/SubordinateTestCase.javaXX"/>

to activate the tests.

> jtax subordinate TransactionImple confuses TwoPhaseOutcome and ActionStatus
> ---------------------------------------------------------------------------
>
>                 Key: JBTM-506
>                 URL: https://jira.jboss.org/jira/browse/JBTM-506
>             Project: JBoss Transaction Manager
>          Issue Type: Bug
>      Security Level: Public(Everyone can see) 
>    Affects Versions: 4.5
>            Reporter: Jonathan Halliday
>            Assignee: Mark Little
>             Fix For: 4.6
>
>
> In some methods of com.arjuna.ats.internal.jta.transaction.arjunacore.subordinate.TransactionImple, code of the form
>  int res = subAct.doFoo();
> switch(res)
> case ActionStatus.Bar:
> is found. This is incorrect, as the methods on SubordinateAtomicAction return TwoPhaseOutome not ActionStatus.  In the JTA the SubordinateAtomicAction returns ActionStatus which is probably where the confusion arises, so arguably it's actually the JTAX  SubordinateAtomicTransaction which is at fault, not the TransactionImple.
> Since the case statements will need reworking anyhow, it's probably worth looking that the way 'try to commit but actually have to rollback' is handled. In the JTA this throws RollbackException as the rollback is clean. In the JTAX it results in a HeuristicRollback due to the way the states and exceptions are mapped. This is perhaps less user friendly than it could be.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        



More information about the jbossts-issues mailing list