jackrabbit-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Costin Leau <costin.l...@gmail.com>
Subject Re[2]: transaction implementation
Date Mon, 19 Sep 2005 11:34:12 GMT
>>>Why don't you use JOTM and enlist XAResource in it?
>> There are two TMs - one local and one global. The difference between
>> them is that the localTM is a lightweight approach which you
>> can/should use when you don't want your transaction to be part of the
>> JTA. It's basically just an option which you can use.
>> The second TM enlists the transaction wiht the JTA transaction
>> manager(like JOTM). At first I tried to use JOTM from the beginning
>> but it's a singleton - one instance per VM so basically if you want
>> your repozitory to use local transactions inside an app server or
>> along JOTM you can't.

> Yes, but when you run inside Tomcat, it's the only way :>
> I'd see this
> resolved the way that TM is set in Spring configurtion and its either
> JOTM or some TM taken from JNDI or something totally different... So you
> can enlist resources in your favorote TM just by using JTA API - then
> you don't have to create dummy Xid but relay on external TM 
> implementation. Or am I missing something?
Let's take an example - if you are using JOTM and I enlist the XA
resource to the TM then it will be either enlisted into a new
transaction or in an already existing one and that's not what I want.
Managing the Xids by myself (which is not so elegant again) allows me
to have a very lightweight approach to the whole situation - it's
similar to HibernateTM from orm.hibernate(3) package - a single
resource TM.

I'm trying to. Just have some patience please for 2-3 more days and
I'll commit the code on Sprin Modules with everything in it. I've
already sent some alpha snapshot and it was a mess to compile all the
feedback. Just 2-3 more days and you'll get unit testing, plus
javadocs and hopefully a sample as well.
But if you are really dying :) check out the SM JIRA and you'll find
some uploaded code - again, it's alpha and the structure has/will be

Best regards,
 Costin                            mailto:costin.leau@gmail.com

View raw message