You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@servicemix.apache.org by cmoulliard <cm...@gmail.com> on 2008/04/10 11:07:52 UTC

Is it possible to start or join a transaction at an endpoint ?

Hi,

Is it possible to start or join a transaction at an endpoint ? Mule proposes
in their package the following properties that a user can use when declaring
the transaction of the endpoint (ex : jms:transaction action="ALWAYS_"):

NONE = The endpoint will not participate in any transaction,
ALWAYS_BEGIN = The endpoint will always start a new transaction. If a
transaction already exists an exception will be thrown.
BEGIN_OR_JOIN = The endpoint will start a new transaction if there is no
existing
transaction or else the endpoint will join the existing transaction
ALWAYS_JOIN = The endpoint will always join the existing transaction. If no
transaction exists an exception will be thrown.
JOIN_IF_POSSIBLE = When a transaction exists, the endpoint will join the
transaction. If no transaction exists nothing will be done.

Regards,

Charles
-- 
View this message in context: http://www.nabble.com/Is-it-possible-to-start-or-join-a-transaction-at-an-endpoint---tp16605716p16605716.html
Sent from the ServiceMix - User mailing list archive at Nabble.com.


Re: Is it possible to start or join a transaction at an endpoint ?

Posted by Guillaume Nodet <gn...@gmail.com>.
You can do that easily using spring transaction support and wrap your pojo
in an AOP proxy using spring.
See
http://static.springframework.org/spring/docs/2.0.x/reference/transaction.html#transaction-declarative
FYI, the transactionManager that you can grab from JNDI (using spring JNDI
support) is already a spring PlatformTransactionManager.

On Thu, Apr 10, 2008 at 11:07 AM, cmoulliard <cm...@gmail.com> wrote:

>
> Hi,
>
> Is it possible to start or join a transaction at an endpoint ? Mule
> proposes
> in their package the following properties that a user can use when
> declaring
> the transaction of the endpoint (ex : jms:transaction action="ALWAYS_"):
>
> NONE = The endpoint will not participate in any transaction,
> ALWAYS_BEGIN = The endpoint will always start a new transaction. If a
> transaction already exists an exception will be thrown.
> BEGIN_OR_JOIN = The endpoint will start a new transaction if there is no
> existing
> transaction or else the endpoint will join the existing transaction
> ALWAYS_JOIN = The endpoint will always join the existing transaction. If
> no
> transaction exists an exception will be thrown.
> JOIN_IF_POSSIBLE = When a transaction exists, the endpoint will join the
> transaction. If no transaction exists nothing will be done.
>
> Regards,
>
> Charles
> --
> View this message in context:
> http://www.nabble.com/Is-it-possible-to-start-or-join-a-transaction-at-an-endpoint---tp16605716p16605716.html
> Sent from the ServiceMix - User mailing list archive at Nabble.com.
>
>


-- 
Cheers,
Guillaume Nodet
------------------------
Blog: http://gnodet.blogspot.com/