Bugs item #792120, was opened at 2003-08-20 12:21
Message generated for change (Comment added) made by starksm
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=376685&aid=792120&group_id=22866

Category: JBossCX
Group: v3.2
Status: Open
Resolution: None
Priority: 8
Submitted By: Jim Cook (oravecz)
Assigned to: Nobody/Anonymous (nobody)
Summary: Local transaction broken when using pass-by-value

Initial Comment:
jBoss 3.2.2 branch, HEAD



In order to get transactional support when using local-

tx-datasource, each time a connection is fetched from 

the pool, the server is supposed to hand you the same 

underlying connection object as long as you are in the 

same transactional context (and on the same server, of 

course). I assume that the server uses some sort of 

ThreadLocal-type algorithm to keep this straight.



Now, since switching to a pass-by-value configuration, 

it seems that the server is no longer handing back the 

same underlying connection. In fact, in a single 

J2EE "transaction" is creating 3 connections to the 

database. Since this is not an XA transactional setup, 

these connections are not actually transactional. They 

are also causing all kinds of deadlocks also, but that 

would be expected given the problem.



I have attached a log4j output that demonstrates that 

a new connection to Sybase is created for every RMI 

thread in use. Since we are using pass-by-value JNDI, a 

new RMI thread is created every time we leave a 

deployment context. I had to move to pass-by-value to 

satisfy the class loading restrictions imposed by jBoss 

3.2.



----------------------------------------------------------------------

>Comment By: Scott M Stark (starksm)
Date: 2003-09-02 14:28

Message:
Logged In: YES 
user_id=175228

Set the org.jboss.tm and the org.jboss.resource categories

in the conf/log4j.xml file to enable trace level logging of

the tm and connection factories. Also attach your jboss

descriptors that are setting up the by value configuration.



   <category name="org.jboss.tm">

     <priority value="TRACE" class="org.jboss.logging.XLevel"/>

   </category>

   <category name="org.jboss.resource">

     <priority value="TRACE" class="org.jboss.logging.XLevel"/>

   </category>



----------------------------------------------------------------------

Comment By: Jim Cook (oravecz)
Date: 2003-08-27 13:22

Message:
Logged In: YES 
user_id=6215

So does this imply that a new transaction is getting created 

(incorrectly) because of the pass-by-value semantics? How 

can I log details of the current transaction?

----------------------------------------------------------------------

Comment By: David Jencks (d_jencks)
Date: 2003-08-21 20:34

Message:
Logged In: YES 
user_id=60525

The local tx connection manager uses a tx to ManagedConnection 

map to keep track of the transaction to ManagedConnection 

association.  I think it is unlikely that this is failing.  



If anyone investigates this, I would suggest starting by 

determining if the new "RMI thread" actually has the correct 

transaction associated with it.  I don't know of any mechanism in 

JBoss 3.2 by which this could occur.

----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=376685&aid=792120&group_id=22866


-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
_______________________________________________
JBoss-Development mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-development

Reply via email to