You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@jackrabbit.apache.org by qcfireball <qc...@yahoo.com> on 2008/01/03 15:16:09 UTC

Re: How does JackRabbit support transaction?



bfxw wrote:
> 
> Hi
>    I don't know how to use transaction in jackrabbit,can anyone help me? I
> don't want to use class - "XASesssion" in my code. I try to use
> userTransaction ,but failed, does jackrabbit support trancation by
> userTransaction?
> 
> thanks in advance.
> 


The JSR 170 doc, page 225 paragraph 6, the end of the paragraph 'The JTA
interfaces javax.transaction.TransactionManager and
javax.transaction.Transaction are the relevant ones in this context (though
the client, as mentioned, will never have a need to use these).'  

This statement in combination with paragraph 4 seems to imply that if the
JSR 170 implementation supports transactions, they are automatically used. 
However, it seems that there is a "user/client controllable" Transaction
available in addition to the "automatic" transaction.

Does this mean that if I make 50 modifications after creating a new Session,
and upon calling 'save()', if any one of the modifications fail, then none
of the modifications are persisted?

I am going to test this just to see for myself, but I'm wondering if someone
can answer this question definitively?

Thanks.
-- 
View this message in context: http://www.nabble.com/How-does-JackRabbit-support-transaction--tp14431374p14597623.html
Sent from the Jackrabbit - Users mailing list archive at Nabble.com.