Starting a new Transaction

Discussions

General J2EE: Starting a new Transaction

  1. Starting a new Transaction (2 messages)

    i have two methods in a stateless Session Bean which has methods methodA ( Required New ) and methodB( required New ). methodA internally calls methodB. If i remotely invoke methodA, does methodB will create a New Transaction other than the transaction of methodA.

    Do i need to create a new instance of the sessionBean within methodA and then call method B to achieve this so that it is a remote invocation ?

    thx
    Gus

    Threaded Messages (2)

  2. Starting a new Transaction[ Go to top ]

    You need to create a new instance of the session bean and call method B via the remote interface in order for it to initiate a new transaction. Otherwise the call to an method B is part of method A's transaction as the container does not recognise that it needs to demarcate a new transaction.
  3. Starting a new Transaction[ Go to top ]

    You have to use remote interface of the methodB to start new transaction