[
http://jira.jboss.com/jira/browse/JBAS-5171?page=comments#action_12396663 ]
Adrian Brock commented on JBAS-5171:
------------------------------------
I've put the check in the TxConnectionManager. So now setting it to
"LocalTransactions"
will also enable the transaction affinity tracking (regardless of broken metadata).
But this still needs fixing properly in the metadata layer.
[ejort@warjort connector]$ svn diff
Index: src/main/org/jboss/resource/connectionmanager/TxConnectionManager.java
===================================================================
--- src/main/org/jboss/resource/connectionmanager/TxConnectionManager.java (revision
69169)
+++ src/main/org/jboss/resource/connectionmanager/TxConnectionManager.java (working
copy)
@@ -241,6 +241,8 @@
public void setLocalTransactions(boolean localTransactions)
{
this.localTransactions = localTransactions;
+ if (localTransactions == true)
+ setTrackConnectionByTx(true);
}
TxConnectionManager is track-connection-by-tx false by default
--------------------------------------------------------------
Key: JBAS-5171
URL:
http://jira.jboss.com/jira/browse/JBAS-5171
Project: JBoss Application Server
Issue Type: Bug
Security Level: Public(Everyone can see)
Components: JCA service
Affects Versions: JBossAS-5.0.0.Beta3
Reporter: Adrian Brock
Assigned To: Alexey Loubyansky
Fix For: JBossAS-5.0.0.Beta4
The TxConnectionManager is always configured to be track-connection-by-tx by default.
The old xslt used to do some complicated logic to try to determine the value
XA with track-connection-by-tx
<xsl:choose>
<xsl:when test="(xa-transaction) and (track-connection-by-tx)">
<attribute name="TrackConnectionByTx">true</attribute>
<attribute name="LocalTransactions">false</attribute>
</xsl:when>
XA with interleaving
<xsl:when test="(xa-transaction)">
<attribute name="TrackConnectionByTx">false</attribute>
<attribute name="LocalTransactions">false</attribute>
</xsl:when>
Non XA MUST BE track-connection-by-tx
<xsl:otherwise>
<attribute name="TrackConnectionByTx">true</attribute>
<attribute name="LocalTransactions">true</attribute>
</xsl:otherwise>
</xsl:choose>
The last part is not being done by the new connection factory deployer/metadata.
In fact, to simplify it (and answer some FAQs), I suggested that
<track-connection-by-tx/> should be "dropped" and set to true all the time
(with a warning about deprecation when somebody tries to use it).
Instead users of XA should explicity enable <interleaving/>
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira