users@glassfish.java.net

Re: RE: UserTransaction lookup failed.

From: <glassfish_at_javadesktop.org>
Date: Thu, 20 Aug 2009 09:02:39 PDT

[This might be wrong so Martin/anyone should correct if so :-].

You have a CMP with mandatory attribute. This means that every method invocation must be performed within the context of a transaction - either the container will create one or the one already in existent when the method is invoked will be used. [b]AFAIK[/b] this will be a JTA transaction, of which UserTransaction is an example.

You are then trying to create a new JTA transaction within an existing JTA transaction. [b]AFAIK[/b] such nesting of transactions just is not supported by JTA, hence the error.

I know there are reasons for wanting to do stuff in a separate transaction, and I think there are supported ways of doing this, but I don't know what they are off the top of my head.
[Message sent by forum member 'matterbury' (matterbury)]

http://forums.java.net/jive/thread.jspa?messageID=361422