SFSB and BMT JTA Transaction Scope confusion

Hi,
I'm a bit confused with the scope of a UserTransaction.
* Classic SFSB with BMT
@Stateful
@TransactionManagement(TransactionManagementType.BEAN)
public class SFSBean implements SFS {
     private @Resource UserTransaction tx;
     private @PersistenceUnit(unitName="my-db") EntityManagerFactory emf;
     private EntityManager em;
     public void start() {
          try {
               tx.begin();
          } catch (NotSupportedException e) {
               throw new RuntimeException(e);
          } catch (SystemException e) {
               throw new RuntimeException(e);
          em = emf.createEntityManager();
     public void doJob1() {
     public void doJob2() {
     @Remove
     public void commit() {
          try {
               tx.commit();
          } catch (SecurityException e) {
               throw new RuntimeException(e);
          } catch (IllegalStateException e) {
               throw new RuntimeException(e);
          } catch (RollbackException e) {
               throw new RuntimeException(e);
          } catch (HeuristicMixedException e) {
               throw new RuntimeException(e);
          } catch (HeuristicRollbackException e) {
               throw new RuntimeException(e);
          } catch (SystemException e) {
               throw new RuntimeException(e);
     @Remove
     public void rollback() {
          try {
               tx.rollback();
          } catch (IllegalStateException e) {
               e.printStackTrace();
          } catch (SecurityException e) {
               e.printStackTrace();
          } catch (SystemException e) {
               e.printStackTrace();
}When I request this SB the container inject a JTA transaction inside my variable tx and this transaction will be bound to the life of my SB.
But : if a handler for this SB is associated to a SessionScoped or ConversationScoped bean (CDI contexts) or simply to a HttpSession attribute, then calls to SB methods may occurs in different thread (successives requests).
Is this pattern supported? As JTA rely on ThreadLocal but a transaction can also be injected inside a SFSB: I'm a bit confused...
HttpRequest1[Thread-1] : ejbHandler.start(); // conversation start
HttpRequest2[Thread-2] : ejbHandler.doJob1(); // long running transaction
HttpRequest3[Thread-1] : ejbHandler.doJob2(); // long running transaction
HttpRequest4[Thread-3] : ejbHandler.commit(); // conversation end
I tried a small use case and it seems to work (maybe all my requests was part of the same thread, lucky me) with JBoss but if an error occurs the transaction manager seems completely confused.
If this pattern is legal (I know it is a very bad pattern...), I'll try to fix my code, if it isn't I'll have to drop JTA from this part of the code...
Thank you.

Yes, this is part of the required transactional behavior for a stateful session bean. A stateful session bean is the only session bean type whose bean instances can retain their association with a transaction after the business method returns. It's then the container's job to set up the correct transaction context for each successive invocation of the stateful session bean instance, until the transaction is committed or rolled back. If a system exception is thrown from the stateful session bean method the instance will be destroyed.

Similar Messages

  • Coherence and EclipseLink - JTA Transaction Manager - slow response times

    A colleague and I are updating a transactional web service to use Coherence as an underlying L2 cache. The application has the following characteristics:
    Java 1.7
    Using Spring Framework 4.0.5
    EclipseLink 12.1.2
    TopLink grid 12.1.2
    Coherence 12.1.2
    javax.persistence 12.1.2
    The application is split, with a GAR in a WebLogic environment and the actual web service application deployed into IBM WebSphere 8.5.
    When we execute a GET from the server for a decently sized piece of data, the response time is roughly 20-25 seconds. From looking into DynaTrace, it appears that we're hitting a brick wall at the "calculateChanges" method within EclipseLink. Looking further, we appear to be having issues with the transaction manager but we're not sure what. If we have a local resource transaction manager, the response time is roughly 500 milliseconds for the exact same request. When the JTA transaction manager is involved, it's 20-25 seconds.
    Is there a recommendation on how to configure the transaction manager when incorporating Coherence into a web service application of this type?

    Hi Volker/Markus,
    Thanks a lot for the response.
    Yeah Volker, you are absolutely right. the 10-12 seconds happens when we have not used the transaction for several minutes...Looks like the transactions are moved away from the SAP buffer or something, in a very short time.
    and yes, the ABAP WP's are running in Pool 2 (*BASE) and the the JAVA server, I have set up in another memory pool of 7 GB's.
    I would say the performance of the JAVA part is much better than the ABAP part.
    Should I just remove the ABAP part of the SOLMAN from memory pool 2 and assign the JAVA/ABAP a separate huge memory pool  of say like 12-13 GB's.
    Will that likely to improve my performance??
    No, I have not deactivated RSDB_TDB in TCOLL from daily twice to weekly once on all systems on this box. It is running daily twice right now.
    Should I change it to weekly once on all the systems on this box?  How is that going to help me?? The only thinng I can think of is that it will save me some CPU utilization, as considerable CPU resources are needed for this program to run.
    But my CPU utilization is anyway only like 30 % average. Its a i570 hardware and right now running 5 CPU's.
    So you still think I should deactivate this job from daily twice to weekly once on all systems on this box??
    Markus, Did you open up any messages with SAP on this issue.?
    I remember working on the 3.2 version of soultion manager on change management and the response times very much better than this as compared to 4.0.
    Let me know guys and once again..thanks a lot for your help and valuable input.
    Abhi

  • SUSPENDING JTA Transaction

    Hi,
    I'm using TOPLINK in WebLogic 10.3.0 environment.
    Toplink session.xml is configured to use external transaction menager (the JTA).
    My Methods using Toplink work in a JTA transaction created by a JMS MDB:
    In order to avout JTA Transactions to Time-out, is it possible to create a new local transaction (the same happening in EJB when RequireNew is the transaction attribute) suspending the main (JTA exernal) transaction?
    How should I proceed?
    Thank you very much.
    L.D

    TopLink will hook into the currently active JTA transaction, and cannot control the transaction itself.  You will need to look in WebLogic docs on how to suspend and resume JTA transactions:
    http://docs.oracle.com/cd/E28280_01/web.1111/e13731/jtaapi.htm  
    I don't believe suspending a transaction will avoid a timeout issue though, so you might want reevaluate what is going on within your MDB and potentially break it into multiple transactions.

  • Error handling via CatchAll and JTA transaction error.

    Hi
    soa 10.1.3.5.0
    I have created a test BPEL process where i am updating already completed Human task. I know it's wrong and i am doing it purposely to test error handling mechanism.
    In the same BPEL I added a Catch all handler hoping that this will catch the error and will let me complete the process.
    However BPEL is failing in the Catch All scope with lovely error: JTA transaction is not present or the transaction is not in active state.
    Does anybody know how and why humantask update activity suddenly changes jta transaction state? Any thoughts of how i can catch the error in the situation i described and process it gracefully?
    Thanks for your help!
    piece from domain.log starting from the place where task service failing to update already completed human task.
    <2013-10-10 17:01:00,520> <ERROR> <services.collaxa.cube.services> <*::*> Invalid action on workflow task.
    <2013-10-10 17:01:00,520> <ERROR> <services.collaxa.cube.services> <*::*> Action OUTCOME_UPDATE on task 11d1def534ea1be0:65540537:141a4173a84:-7fa1 is not valid because of .
    <2013-10-10 17:01:00,520> <ERROR> <services.collaxa.cube.services> <*::*> Contact oracle support if error is not fixable.
    <2013-10-10 17:01:00,520> <ERROR> <services.collaxa.cube.services> <*::*>
    <2013-10-10 17:01:00,520> <ERROR> <services.collaxa.cube.services> <*::*>     at oracle.bpel.services.workflow.task.impl.TaskService.performPreActionValidation(TaskService.java:3600)
    <2013-10-10 17:01:00,520> <ERROR> <services.collaxa.cube.services> <*::*>     at oracle.bpel.services.workflow.task.impl.TaskService.performPreActionValidation(TaskService.java:3557)
    <2013-10-10 17:01:00,521> <ERROR> <services.collaxa.cube.services> <*::*>     at oracle.bpel.services.workflow.task.impl.TaskService.updateTaskOutcomeAndEvaluateRoutingSlip(TaskService.java:1139)
    <2013-10-10 17:01:00,521> <ERROR> <services.collaxa.cube.services> <*::*>     at oracle.bpel.services.workflow.task.impl.TaskService.updateTaskOutcome(TaskService.java:1006)
    <2013-10-10 17:01:00,521> <ERROR> <services.collaxa.cube.services> <*::*>     at oracle.bpel.services.workflow.task.impl.TaskService.updateTaskOutcome(TaskService.java:985)
    <2013-10-10 17:01:00,521> <ERROR> <services.collaxa.cube.services> <*::*>     at oracle.bpel.services.workflow.task.ejb.TaskServiceBean.updateTaskOutcome(TaskServiceBean.java:409)
    <2013-10-10 17:01:00,521> <ERROR> <services.collaxa.cube.services> <*::*>     at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    <2013-10-10 17:01:00,521> <ERROR> <services.collaxa.cube.services> <*::*>     at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    <2013-10-10 17:01:00,521> <ERROR> <services.collaxa.cube.services> <*::*>     at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    <2013-10-10 17:01:00,521> <ERROR> <services.collaxa.cube.services> <*::*>     at java.lang.reflect.Method.invoke(Method.java:597)
    <2013-10-10 17:01:00,521> <ERROR> <services.collaxa.cube.services> <*::*>     at com.evermind.server.ejb.interceptor.joinpoint.EJBJoinPointImpl.invoke(EJBJoinPointImpl.java:35)
    <2013-10-10 17:01:00,521> <ERROR> <services.collaxa.cube.services> <*::*>     at com.evermind.server.ejb.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:119)
    <2013-10-10 17:01:00,521> <ERROR> <services.collaxa.cube.services> <*::*>     at com.evermind.server.ejb.interceptor.system.DMSInterceptor.invoke(DMSInterceptor.java:52)
    <2013-10-10 17:01:00,521> <ERROR> <services.collaxa.cube.services> <*::*>     at com.evermind.server.ejb.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:119)
    <2013-10-10 17:01:00,522> <ERROR> <services.collaxa.cube.services> <*::*>     at com.evermind.server.ejb.interceptor.system.JAASInterceptor$1.run(JAASInterceptor.java:31)
    <2013-10-10 17:01:00,522> <ERROR> <services.collaxa.cube.services> <*::*>     at com.evermind.server.ThreadState.runAs(ThreadState.java:705)
    <2013-10-10 17:01:00,522> <ERROR> <services.collaxa.cube.services> <*::*>     at com.evermind.server.ejb.interceptor.system.JAASInterceptor.invoke(JAASInterceptor.java:34)
    <2013-10-10 17:01:00,522> <ERROR> <services.collaxa.cube.services> <*::*>     at com.evermind.server.ejb.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:119)
    <2013-10-10 17:01:00,522> <ERROR> <services.collaxa.cube.services> <*::*>     at com.evermind.server.ejb.interceptor.system.TxRequiredInterceptor.invoke(TxRequiredInterceptor.java:50)
    <2013-10-10 17:01:00,522> <ERROR> <services.collaxa.cube.services> <*::*>     at com.evermind.server.ejb.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:119)
    <2013-10-10 17:01:00,522> <ERROR> <services.collaxa.cube.services> <*::*>     at com.evermind.server.ejb.interceptor.system.DMSInterceptor.invoke(DMSInterceptor.java:52)
    <2013-10-10 17:01:00,522> <ERROR> <services.collaxa.cube.services> <*::*>     at com.evermind.server.ejb.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:119)
    <2013-10-10 17:01:00,522> <ERROR> <services.collaxa.cube.services> <*::*>     at com.evermind.server.ejb.InvocationContextPool.invoke(InvocationContextPool.java:55)
    <2013-10-10 17:01:00,522> <ERROR> <services.collaxa.cube.services> <*::*>     at com.evermind.server.ejb.StatelessSessionEJBObject.OC4J_invokeMethod(StatelessSessionEJBObject.java:87)
    <2013-10-10 17:01:00,523> <ERROR> <services.collaxa.cube.services> <*::*>     at TaskServiceBean_LocalProxy_68d4144.updateTaskOutcome(Unknown Source)
    <2013-10-10 17:01:00,523> <ERROR> <services.collaxa.cube.services> <*::*>     at oracle.bpel.services.workflow.task.client.TaskServiceLocalClient.updateTaskOutcome(TaskServiceLocalClient.java:678)
    <2013-10-10 17:01:00,523> <ERROR> <services.collaxa.cube.services> <*::*>     at oracle.bpel.services.workflow.task.impl.TaskServiceWSIF.updateTaskOutcome(TaskServiceWSIF.java:580)
    <2013-10-10 17:01:00,523> <ERROR> <services.collaxa.cube.services> <*::*>     at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    <2013-10-10 17:01:00,523> <ERROR> <services.collaxa.cube.services> <*::*>     at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    <2013-10-10 17:01:00,523> <ERROR> <services.collaxa.cube.services> <*::*>     at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    <2013-10-10 17:01:00,523> <ERROR> <services.collaxa.cube.services> <*::*>     at java.lang.reflect.Method.invoke(Method.java:597)
    <2013-10-10 17:01:00,523> <ERROR> <services.collaxa.cube.services> <*::*>     at com.collaxa.cube.ws.wsif.providers.java.WSIFOperation_Java.executeRequestResponseOperation(WSIFOperation_Java.java:1019)
    <2013-10-10 17:01:00,523> <ERROR> <services.collaxa.cube.services> <*::*>     at com.collaxa.cube.ws.WSIFInvocationHandler.invoke(WSIFInvocationHandler.java:480)
    <2013-10-10 17:01:00,523> <ERROR> <services.collaxa.cube.services> <*::*>     at com.collaxa.cube.ws.WSInvocationManager.invoke2(WSInvocationManager.java:538)
    <2013-10-10 17:01:00,523> <ERROR> <services.collaxa.cube.services> <*::*>     at com.collaxa.cube.ws.WSInvocationManager.invoke(WSInvocationManager.java:286)
    <2013-10-10 17:01:00,523> <ERROR> <services.collaxa.cube.services> <*::*>     at com.collaxa.cube.engine.ext.wmp.BPELInvokeWMP.__invoke(BPELInvokeWMP.java:832)
    <2013-10-10 17:01:00,523> <ERROR> <services.collaxa.cube.services> <*::*>     at com.collaxa.cube.engine.ext.wmp.BPELInvokeWMP.__executeStatements(BPELInvokeWMP.java:413)
    <2013-10-10 17:01:00,523> <ERROR> <services.collaxa.cube.services> <*::*>     at com.collaxa.cube.engine.ext.wmp.BPELActivityWMP.perform(BPELActivityWMP.java:200)
    <2013-10-10 17:01:00,524> <ERROR> <services.collaxa.cube.services> <*::*>     at com.collaxa.cube.engine.CubeEngine.performActivity(CubeEngine.java:4326)
    <2013-10-10 17:01:00,524> <ERROR> <services.collaxa.cube.services> <*::*>     at com.collaxa.cube.engine.CubeEngine.handleWorkItem(CubeEngine.java:1839)
    <2013-10-10 17:01:00,524> <ERROR> <services.collaxa.cube.services> <*::*>     at com.collaxa.cube.engine.dispatch.message.instance.PerformMessageHandler.handleLocal(PerformMessageHandler.java:77)
    <2013-10-10 17:01:00,524> <ERROR> <services.collaxa.cube.services> <*::*>     at com.collaxa.cube.engine.dispatch.DispatchHelper.handleLocalMessage(DispatchHelper.java:240)
    <2013-10-10 17:01:00,524> <ERROR> <services.collaxa.cube.services> <*::*>     at com.collaxa.cube.engine.dispatch.DispatchHelper.sendMemory(DispatchHelper.java:345)
    <2013-10-10 17:01:00,524> <ERROR> <services.collaxa.cube.services> <*::*>     at com.collaxa.cube.engine.CubeEngine.endRequest(CubeEngine.java:6460)
    <2013-10-10 17:01:00,524> <ERROR> <services.collaxa.cube.services> <*::*>     at com.collaxa.cube.engine.CubeEngine.expireActivity(CubeEngine.java:2267)
    <2013-10-10 17:01:00,524> <ERROR> <services.collaxa.cube.services> <*::*>     at com.collaxa.cube.ejb.impl.ActivityManagerBean.expireActivity(ActivityManagerBean.java:185)
    <2013-10-10 17:01:00,524> <ERROR> <services.collaxa.cube.services> <*::*>     at com.collaxa.cube.ejb.impl.ActivityManagerBean.expireActivity(ActivityManagerBean.java:156)
    <2013-10-10 17:01:00,524> <ERROR> <services.collaxa.cube.services> <*::*>     at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    <2013-10-10 17:01:00,524> <ERROR> <services.collaxa.cube.services> <*::*>     at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    <2013-10-10 17:01:00,525> <ERROR> <services.collaxa.cube.services> <*::*>     at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    <2013-10-10 17:01:00,525> <ERROR> <services.collaxa.cube.services> <*::*>     at java.lang.reflect.Method.invoke(Method.java:597)
    <2013-10-10 17:01:00,525> <ERROR> <services.collaxa.cube.services> <*::*>     at com.evermind.server.ejb.interceptor.joinpoint.EJBJoinPointImpl.invoke(EJBJoinPointImpl.java:35)
    <2013-10-10 17:01:00,525> <ERROR> <services.collaxa.cube.services> <*::*>     at com.evermind.server.ejb.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:119)
    <2013-10-10 17:01:00,525> <ERROR> <services.collaxa.cube.services> <*::*>     at com.evermind.server.ejb.interceptor.system.DMSInterceptor.invoke(DMSInterceptor.java:52)
    <2013-10-10 17:01:00,525> <ERROR> <services.collaxa.cube.services> <*::*>     at com.evermind.server.ejb.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:119)
    <2013-10-10 17:01:00,525> <ERROR> <services.collaxa.cube.services> <*::*>     at com.evermind.server.ejb.interceptor.system.JAASInterceptor$1.run(JAASInterceptor.java:31)
    <2013-10-10 17:01:00,525> <ERROR> <services.collaxa.cube.services> <*::*>     at com.evermind.server.ThreadState.runAs(ThreadState.java:705)
    <2013-10-10 17:01:00,525> <ERROR> <services.collaxa.cube.services> <*::*>     at com.evermind.server.ejb.interceptor.system.JAASInterceptor.invoke(JAASInterceptor.java:34)
    <2013-10-10 17:01:00,525> <ERROR> <services.collaxa.cube.services> <*::*>     at com.evermind.server.ejb.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:119)
    <2013-10-10 17:01:00,525> <ERROR> <services.collaxa.cube.services> <*::*>     at com.evermind.server.ejb.interceptor.system.TxRequiredInterceptor.invoke(TxRequiredInterceptor.java:50)
    <2013-10-10 17:01:00,525> <ERROR> <services.collaxa.cube.services> <*::*>     at com.evermind.server.ejb.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:119)
    <2013-10-10 17:01:00,525> <ERROR> <services.collaxa.cube.services> <*::*>     at com.evermind.server.ejb.interceptor.system.DMSInterceptor.invoke(DMSInterceptor.java:52)
    <2013-10-10 17:01:00,525> <ERROR> <services.collaxa.cube.services> <*::*>     at com.evermind.server.ejb.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:119)
    <2013-10-10 17:01:00,526> <ERROR> <services.collaxa.cube.services> <*::*>     at com.evermind.server.ejb.InvocationContextPool.invoke(InvocationContextPool.java:55)
    <2013-10-10 17:01:00,526> <ERROR> <services.collaxa.cube.services> <*::*>     at com.evermind.server.ejb.StatelessSessionEJBObject.OC4J_invokeMethod(StatelessSessionEJBObject.java:87)
    <2013-10-10 17:01:00,526> <ERROR> <services.collaxa.cube.services> <*::*>     at ActivityManagerBean_LocalProxy_4bin6i8.expireActivity(Unknown Source)
    <2013-10-10 17:01:00,526> <ERROR> <services.collaxa.cube.services> <*::*>     at com.collaxa.cube.engine.dispatch.message.instance.ExpirationMessageHandler.handle(ExpirationMessageHandler.java:43)
    <2013-10-10 17:01:00,526> <ERROR> <services.collaxa.cube.services> <*::*>     at com.collaxa.cube.engine.dispatch.DispatchHelper.handleMessage(DispatchHelper.java:150)
    <2013-10-10 17:01:00,526> <ERROR> <services.collaxa.cube.services> <*::*>     at com.collaxa.cube.engine.dispatch.BaseDispatchTask.run(BaseDispatchTask.java:58)
    <2013-10-10 17:01:00,526> <ERROR> <services.collaxa.cube.services> <*::*>     at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
    <2013-10-10 17:01:00,526> <ERROR> <services.collaxa.cube.services> <*::*>     at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
    <2013-10-10 17:01:00,526> <ERROR> <services.collaxa.cube.services> <*::*>     at java.lang.Thread.run(Thread.java:662)
    <2013-10-10 17:01:00,526> <ERROR> <services.collaxa.cube.services> <*::*> Caused by: ORABPEL-30036
    <2013-10-10 17:01:00,526> <ERROR> <services.collaxa.cube.services> <*::*>
    <2013-10-10 17:01:00,526> <ERROR> <services.collaxa.cube.services> <*::*> Invalid action on workflow task.
    <2013-10-10 17:01:00,526> <ERROR> <services.collaxa.cube.services> <*::*> Action OUTCOME_UPDATE on task 11d1def534ea1be0:65540537:141a4173a84:-7fa1 is not valid because of The task has been completed..
    <2013-10-10 17:01:00,527> <ERROR> <services.collaxa.cube.services> <*::*> Contact oracle support if error is not fixable.
    <2013-10-10 17:01:00,527> <ERROR> <services.collaxa.cube.services> <*::*>
    <2013-10-10 17:01:00,527> <ERROR> <services.collaxa.cube.services> <*::*>     at oracle.bpel.services.workflow.task.impl.TaskService.performPreActionValidation(TaskService.java:3592)
    <2013-10-10 17:01:00,527> <ERROR> <services.collaxa.cube.services> <*::*>     ... 71 more
    <2013-10-10 17:01:00,562> <ERROR> <services.collaxa.cube.engine> The execution of this instance "390003" for process "MY_BPEL_PROCESS" is supposed to be in a jta transaction, but the transaction is not present or in active state, please turn on the application server transaction debug logs to get more information.
    <2013-10-10 17:01:00,571> <WARN> <services.collaxa.cube> <BaseCubeSessionBean::logError> Error while invoking bean "activity manager": Failed due to unhandled bpel fault.
    <2013-10-10 17:01:00,584> <ERROR> <services.collaxa.cube.engine.dispatch> <DispatchHelper::handleMessage> failed to handle message
    ORABPEL-02182
    JTA transaction is not present or the transaction is not in active state.
    The current JTA transaction is not present or it is not in active state when processing activity or instance "390,003". The reason is The execution of this instance "390003" for process "MY_BPEL_PROCESS" is supposed to be in a jta transaction, but the transaction is not present or in active state, please turn on the application server transaction debug logs to get more information..
    Please consult your administrator regarding this error.
        at com.collaxa.cube.engine.CubeEngine.store(CubeEngine.java:6176)
        at com.collaxa.cube.engine.CubeEngine.endRequest(CubeEngine.java:6482)
        at com.collaxa.cube.engine.CubeEngine.expireActivity(CubeEngine.java:2267)
        at com.collaxa.cube.ejb.impl.ActivityManagerBean.expireActivity(ActivityManagerBean.java:185)
        at com.collaxa.cube.ejb.impl.ActivityManagerBean.expireActivity(ActivityManagerBean.java:156)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:597)
        at com.evermind.server.ejb.interceptor.joinpoint.EJBJoinPointImpl.invoke(EJBJoinPointImpl.java:35)
        at com.evermind.server.ejb.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:119)
        at com.evermind.server.ejb.interceptor.system.DMSInterceptor.invoke(DMSInterceptor.java:52)
        at com.evermind.server.ejb.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:119)
        at com.evermind.server.ejb.interceptor.system.JAASInterceptor$1.run(JAASInterceptor.java:31)
        at com.evermind.server.ThreadState.runAs(ThreadState.java:705)
        at com.evermind.server.ejb.interceptor.system.JAASInterceptor.invoke(JAASInterceptor.java:34)
        at com.evermind.server.ejb.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:119)
        at com.evermind.server.ejb.interceptor.system.TxRequiredInterceptor.invoke(TxRequiredInterceptor.java:50)
        at com.evermind.server.ejb.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:119)
        at com.evermind.server.ejb.interceptor.system.DMSInterceptor.invoke(DMSInterceptor.java:52)
        at com.evermind.server.ejb.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:119)
        at com.evermind.server.ejb.InvocationContextPool.invoke(InvocationContextPool.java:55)
        at com.evermind.server.ejb.StatelessSessionEJBObject.OC4J_invokeMethod(StatelessSessionEJBObject.java:87)
        at ActivityManagerBean_LocalProxy_4bin6i8.expireActivity(Unknown Source)
        at com.collaxa.cube.engine.dispatch.message.instance.ExpirationMessageHandler.handle(ExpirationMessageHandler.java:43)
        at com.collaxa.cube.engine.dispatch.DispatchHelper.handleMessage(DispatchHelper.java:150)
        at com.collaxa.cube.engine.dispatch.BaseDispatchTask.run(BaseDispatchTask.java:58)
        at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
        at java.lang.Thread.run(Thread.java:662)
    <2013-10-10 17:01:00,585> <ERROR> <services.collaxa.cube.engine.dispatch> <DispatchHelper::handleMessage> Not fatal connection error ... not retrying: class com.collaxa.cube.engine.UnhandledFaultException: Failed due to unhandled bpel fault.
    <2013-10-10 17:01:00,593> <ERROR> <services.collaxa.cube.engine.dispatch> <BaseDispatchTask::run> Failed to handle dispatch message ... exception ORABPEL-05002
    Message handle error.
    An exception occurred while attempting to process the message "com.collaxa.cube.engine.dispatch.message.instance.ExpirationMessage"; the exception is: JTA transaction is not present or the transaction is not in active state.
    The current JTA transaction is not present or it is not in active state when processing activity or instance "390,003". The reason is The execution of this instance "390003" for process "MY_BPEL_PROCESS" is supposed to be in a jta transaction, but the transaction is not present or in active state, please turn on the application server transaction debug logs to get more information..
    Please consult your administrator regarding this error.
    ORABPEL-05002
    Message handle error.
    An exception occurred while attempting to process the message "com.collaxa.cube.engine.dispatch.message.instance.ExpirationMessage"; the exception is: JTA transaction is not present or the transaction is not in active state.
    The current JTA transaction is not present or it is not in active state when processing activity or instance "390,003". The reason is The execution of this instance "390003" for process "MY_BPEL_PROCESS" is supposed to be in a jta transaction, but the transaction is not present or in active state, please turn on the application server transaction debug logs to get more information..
    Please consult your administrator regarding this error.
        at com.collaxa.cube.engine.dispatch.DispatchHelper.handleMessage(DispatchHelper.java:226)
        at com.collaxa.cube.engine.dispatch.BaseDispatchTask.run(BaseDispatchTask.java:58)
        at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
        at java.lang.Thread.run(Thread.java:662)

    If you look at the error, it suggests that the action you are performing is invalid.That is you cannot update human task which has been already completed. Thats why you are getting that "JTA transaction not active error". Since your human task has already been completed, it is not able to update it again.
    <2013-10-10 17:01:00,526> <ERROR> <services.collaxa.cube.services> <*::*> Caused by: ORABPEL-30036
    <2013-10-10 17:01:00,526> <ERROR> <services.collaxa.cube.services> <*::*>
    <2013-10-10 17:01:00,526> <ERROR> <services.collaxa.cube.services> <*::*> Invalid action on workflow task.
    <2013-10-10 17:01:00,526> <ERROR> <services.collaxa.cube.services> <*::*> Action OUTCOME_UPDATE on task 11d1def534ea1be0:65540537:141a4173a84:-7fa1 is not valid because of The task has been completed..
    <2013-10-10 17:01:00,527> <ERROR> <services.collaxa.cube.services> <*::*> Contact oracle support if error is not fixable.
    <2013-10-10 17:01:00,527> <ERROR> <services.collaxa.cube.services> <*::*>
    May be you can try some other usecase ? Also could you let me know whether you are getting this error in logs only or in your composite instance as well. I mean whether the instance gets successfully terminated or completed ??
    Regards,
    Karan

  • EJB3 Interceptors and JTA transaction management

    Hi,
    Are Interceptors part of the JTA transaction?
    can we perform there rollback for example?
    What if the EJB transaction setting is NONE?
    Thanks in advance,
    Tal.

    user6098247 wrote:
    Hi,
    Are Interceptors part of the JTA transaction?Yes - the spec mandates that. Interceptor methods execute in the same security and transaction context as the associated bean method.
    can we perform there rollback for example?
    For CMT? It is possible to inject the ejbContext object into the Interceptor and use it in the same manner you would in a bean to mark the tx for rollback.
    What if the EJB transaction setting is NONE?
    Again the behavior is the same as in a bean.
    ram.

  • Two phase commit and bean managed transactions

    To all the Transaction GURUS!
              Hi guys (-and gals).
              I've been doing J2EE for quite a while, but today was my first at
              XA-Transactions and Bean Managed Transactions.
              Why am I doing this?
              ====================
              Well I have to be able to controll the transactionalbehaviour of my
              bean
              during runtime, since some bean calls would cause a transactional
              overflow due to the stress they would cause to the system, whereas
              smaller bean calls need to run in one transaction.
              -> Therefore I need Bean Managed Transactions
              Since the bean does a call on two Database Connections it has to use a
              XA-Transaction.
              -> Therefore I need XA-Transactions.
              Abstract
              ========
              - I just can't get a User TransAction into the right Status it stays
              in 'STATUS_NO_TRANSACTION' all the time
              - Therefore the SQL Commands can be comitted 'java.sql.SQLException:
              Does not support SQL execution with no global transaction'
              - Therefore I can't do a rollback 'java.lang.IllegalStateException:
              Transaction does not exist'
              - Therefore I wrote this mail.
              I don't want to be a smart-"ass" writing such a detailed and indepth
              mail. I just would like to show that I tried, and would like to have
              some replies from you guys.
              Below are my configurations, code and logfiles.
              Thanx for taking your time and hope that the other people may learn
              something as well.
              cu
              Stefan
              Scenario
              ========
              used Software
              Bea Weblogic (WL) 6.0 SPx (not real sure which SP i have)
              Oracle 8.1.6 using the API-Version 8
              I configured the system as follows:
              (ofcourse I 'xxx'ed out all of the confidential data, sorry guys;-))
              excerpt from:
              config.xml
              <JDBCConnectionPool CapacityIncrement="5"
              DriverName="oracle.jdbc.driver.OracleDriver" InitialCapacity="2"
              LoginDelaySeconds="1" MaxCapacity="5" Name="oraclePool"
              Properties="user=xxx;password=xxx;dll=ocijdbc8;protocol=thin"
              RefreshMinutes="5" Targets="fbsserver" TestConnectionsOnRelease="true"
              TestTableName="languages" URL="jdbc:oracle:thin:@xxx:1521:xxx "/>
              <!-- Since this is our Main Datasource I would not like to use a XA
              Transaction due to performance Issues
              and the TxDataSource:
              -->
              <JDBCTxDataSource EnableTwoPhaseCommit="true"
              JNDIName="finstral.datasource.fbs" Name="finstral Content Datasource"
              PoolName="oraclePool" Targets="fbsserver"/>
              <!-- no comment required -I hope.
              Next comes the "special" Pool
              -->
              <JDBCConnectionPool CapacityIncrement="5"
              DriverName="weblogic.jdbc.oci.xa.XADataSource" InitialCapacity="1"
              LoginDelaySeconds="1" MaxCapacity="2" Name="oracleSecurityPool"
              Properties="user=xxx;password=xxx;server=xxx.xxx.xxx"
              RefreshMinutes="5" Targets="fbsserver" TestConnectionsOnRelease="true"
              TestTableName="Users" SupportsLocalTransaction="true"/>
              <!-- Well since there can only be one none XARessourceManager involved
              in a 2PC
              (keyword: Two Phase Commit) I will have to use a XACapable Driver for
              the other
              Datasource. Due to all the bugs in the oracle.xxx driver. I'll be
              using the jdriver for oci.
              I activated 'SupportsLocalTransaction' hoping it would solve my
              problem - without effect. I just left in there now, since it made
              sense me. Not?
              Again the TxDataSource:
              -->
              <JDBCTxDataSource EnableTwoPhaseCommit="true"
              JNDIName="finstral.datasource.fbssecurity" Name="finstral Security
              Datasource" PoolName="oracleSecurityPool" Targets="fbsserver"/>
              <!-- The System starts right up and can locate the test tables and
              everything. So I think all of this stuff is working here -->
              ejb-jar.xml
              <ejb-jar>
                   <enterprise-beans>
                        <session>
                             <ejb-name>TPCTestBean</ejb-name>
              <home>de.sitewaerts.futuna.common.test.tpcbean.TPCHome</home>
              <remote>de.sitewaerts.futuna.common.test.tpcbean.TPC</remote>
              <ejb-class>de.sitewaerts.futuna.common.test.tpcbean.TPCBean</ejb-class>
                             <session-type>Stateless</session-type>
                             <transaction-type>Bean</transaction-type>
                        </session>
                   </enterprise-beans>
                   <assembly-descriptor/>
              </ejb-jar>
              <!-- Originally I had the assembly-descriptor full of transaction
              requirements. I thought since
              the bean is handling all of the transaction stuff itself, it might get
              confused by the 'container-transaction'
              properties, and deleted them. Do I need them anyway?-->
              weblogic-ejb-jar.xml
              <weblogic-ejb-jar>
                   <weblogic-enterprise-bean>
                        <ejb-name>TPCTestBean</ejb-name>
                        <stateless-session-descriptor/>
                        <jndi-name>finstral/ejb/test_tpc</jndi-name>
                   </weblogic-enterprise-bean>
              </weblogic-ejb-jar>
              <!-- Nothing I have to explain here -->
              BeanCode (from the implementingBeanClass:
              'de.sitewaerts.futuna.common.test.tpcbean.TPCBean')
              public void setupTables() throws RemoteException
              UserTransaction tx = getTransaction();
              //getTransaction calls: 'tx = sCtx.getUserTransaction()' and does
              some errorhandling
              log.info("Die Transaktion vor den Connections: "+tx.toString());
              //Sorry bout the German. You should get the Message though.
              log.info("Der Transaktionsstatus vor den Connections:
              "+transactionStatus(tx));
              Connection conSecurity = getConnection(DATASOURCE_SECURITY, tx);
              //gets a Connection via a DataSourceName from the JNDI tree
              Connection conContent = getConnection(DATASOURCE_CONTENT, tx);
              log.info("Die frische Connection conSecurity: "+conSecurity);
              log.info("Die frische Connection conContent: "+conContent);
              tearDownTable(conSecurity);
              //Does nothing special
              tearDownTable(conContent);
              log.info("Die Transaktion nach dem Teardown: "+tx.toString());
              log.info("Der Transaktionsstatus nach dem Teardown:
              "+transactionStatus(tx));
              Statement stmt = null;
              try
              stmt = conSecurity.createStatement();
              //Well its getting interesting now.....
              log.info("Die Transaktion vor dem createtable: "+tx.toString());
              log.info("Der Transaktionsstatus vor dem createtable:
              "+transactionStatus(tx));
              log.info("Die Connection conSecurity vor dem createtable:
              "+conSecurity);
              log.info("Die Connection conContent vor dem createtable:
              "+conContent);
              stmt.executeUpdate(CREATE_TABLE);
              //above is the row 91 -> throws: 'java.sql.SQLException: Does
              not support SQL execution with no global transaction'
              stmt.close();
              stmt = conContent.createStatement();
              stmt.executeUpdate(CREATE_TABLE);
              stmt.close();
              commitTransaction(tx);
              catch (SQLException sqle)
              log.error("Konnte kein table init machen", sqle);
              rollbackTransaction(tx);
              //The Code for this method is below
              throw new EJBException(sqle);
              finally
              closeConnection(conSecurity);
              closeConnection(conContent);
              protected void rollbackTransaction(UserTransaction tx)
              log.info("Der Transaktionsstatus vor dem Rollback:
              "+transactionStatus(tx));
              log.info("Die Transaktion vor dem Rollback: "+tx.toString());
              try
              tx.rollback();
              //above is row 200 -> throws: 'java.lang.IllegalStateException:
              Transaction does not exist'
              log.info("Der Transaktionsstatus nach dem Rollback:
              "+transactionStatus(tx));
              log.info("Die Transaktion nach dem Rollback: "+tx.toString());
              catch (Exception e)
              log.error("Konnte die Transaktion nicht backrollen.", e);
              throw new EJBException(e);
              Log Excerpt
              ===========
              INFO setupTables() (66) - Die Transaktion vor den Connections:
              [email protected]
              INFO setupTables() (67) - Der Transaktionsstatus vor den Connections:
              STATUS_NO_TRANSACTION
              INFO setupTables() (72) - Die frische Connection conSecurity:
              weblogic.jdbc.rmi.SerialConnection@7c6daa
              INFO setupTables() (73) - Die frische Connection conContent:
              weblogic.jdbc.rmi.SerialConnection@3b425
              INFO setupTables() (78) - Die Transaktion nach dem Teardown:
              [email protected]
              INFO setupTables() (79) - Der Transaktionsstatus nach dem Teardown:
              STATUS_NO_TRANSACTION
              INFO setupTables() (86) - Die Transaktion vor dem createtable:
              [email protected]
              INFO setupTables() (87) - Der Transaktionsstatus vor dem createtable:
              STATUS_NO_TRANSACTION
              INFO setupTables() (88) - Die Connection conSecurity vor dem
              createtable: weblogic.jdbc.rmi.SerialConnection@7c6daa
              INFO setupTables() (89) - Die Connection conContent vor dem
              createtable: weblogic.jdbc.rmi.SerialConnection@3b425
              ERROR setupTables() (101) - Konnte kein table init machen
              java.sql.SQLException: Does not support SQL execution with no global
              transaction
                   at
              weblogic.jdbc.oci.xa.XAConnection.beforeExecute(XAConnection.java:137)
                   at
              weblogic.jdbc.oci.xa.Statement.executeUpdate(Statement.java:112)
                   at weblogic.jdbc.jta.Statement.executeUpdate(Statement.java:185)
                   at
              weblogic.jdbc.rmi.internal.StatementImpl.executeUpdate(StatementImpl.jav
              a:42)
                   at
              weblogic.jdbc.rmi.SerialStatement.executeUpdate(SerialStatement.java:54)
                   at
              de.sitewaerts.futuna.common.test.tpcbean.TPCBean.setupTables(TPCBean.jav
              a:91)
                   at
              de.sitewaerts.futuna.common.test.tpcbean.TPCBeanImpl.setupTables(TPCBean
              Impl.java:130)
                   at
              de.sitewaerts.futuna.common.test.tpcbean.TPCBeanEOImpl.setupTables(TPCBe
              anEOImpl.java:64)
                   at
              de.sitewaerts.futuna.common.test.TwoPhaseCommitUnitTest.setUp(TwoPhaseCo
              mmitUnitTest.java:51)
                   at
              org.apache.commons.cactus.AbstractTestCase.runBareServerTest(AbstractTes
              tCase.java:297)
                   at
              org.apache.commons.cactus.server.ServletTestCaller.callTestMethod(Servle
              tTestCaller.java:148)
                   at
              org.apache.commons.cactus.server.ServletTestCaller.doTest(ServletTestCal
              ler.java:199)
                   at
              org.apache.commons.cactus.server.ServletTestRedirector.doPost(ServletTes
              tRedirector.java:149)
                   at javax.servlet.http.HttpServlet.service(HttpServlet.java:760)
                   at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
                   at
              weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.
              java:213)
                   at
              weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppServl
              etContext.java:1265)
                   at
              weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestImpl.
              java:1631)
                   at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:137)
                   at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:120)
              INFO rollbackTransaction() (196) - Der Transaktionsstatus vor dem
              Rollback: STATUS_NO_TRANSACTION
              INFO rollbackTransaction() (197) - Die Transaktion vor dem Rollback:
              [email protected]
              ERROR rollbackTransaction() (206) - Konnte die Transaktion nicht
              backrollen.
              java.lang.IllegalStateException: Transaction does not exist
                   at
              weblogic.transaction.internal.TransactionManagerImpl.rollback(Transactio
              nManagerImpl.java:228)
                   at
              weblogic.transaction.internal.TransactionManagerImpl.rollback(Transactio
              nManagerImpl.java:222)
                   at
              de.sitewaerts.futuna.common.test.tpcbean.TPCBean.rollbackTransaction(TPC
              Bean.java:200)
                   at
              de.sitewaerts.futuna.common.test.tpcbean.TPCBean.setupTables(TPCBean.jav
              a:102)
                   at
              de.sitewaerts.futuna.common.test.tpcbean.TPCBeanImpl.setupTables(TPCBean
              Impl.java:130)
                   at
              de.sitewaerts.futuna.common.test.tpcbean.TPCBeanEOImpl.setupTables(TPCBe
              anEOImpl.java:64)
                   at
              de.sitewaerts.futuna.common.test.TwoPhaseCommitUnitTest.setUp(TwoPhaseCo
              mmitUnitTest.java:51)
                   at
              org.apache.commons.cactus.AbstractTestCase.runBareServerTest(AbstractTes
              tCase.java:297)
                   at
              org.apache.commons.cactus.server.ServletTestCaller.callTestMethod(Servle
              tTestCaller.java:148)
                   at
              org.apache.commons.cactus.server.ServletTestCaller.doTest(ServletTestCal
              ler.java:199)
                   at
              org.apache.commons.cactus.server.ServletTestRedirector.doPost(ServletTes
              tRedirector.java:149)
                   at javax.servlet.http.HttpServlet.service(HttpServlet.java:760)
                   at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
                   at
              weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.
              java:213)
                   at
              weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppServl
              etContext.java:1265)
                   at
              weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestImpl.
              java:1631)
                   at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:137)
                   at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:120)
              CONCLUSION
              ==========
              I'm going nuts.
              I just don't get it.
              The transaction is the same. I don't change the Connection. I start
              the Transaction at the beginning before I do anything!
              Please guys help me out.
              Thx alot.
              Stefan "it's three o'clock in the morning, my girlfriend left me, and
              my only friend is that stupid linux pinguine" Siprell
              Software-Development
              <<<<<<<<<<<<<<<<<<<<<<<<<<<
              <sitewaerts> GmbH
              Hebelstraße 15
              D-76131 Karlsruhe
              Tel: +49 (721) 920 918 22
              Fax: +49 (721) 920 918 29
              http://www.sitewaerts.de
              >>>>>>>>>>>>>>>>>>>>>>>>>>>
              

    Hi Priscilla
              (did you ever see the movie ? :-))
              Well I moved away from the idea of using bean managed transaction. I'll
              be using Container Managed Transactions. To modify the
              transactionalbehaviour I'll write proxymethods which have certain
              different containermanaged transaction properties, but which all call
              the same private methods.
              But it works! Here is my experience:
              - I was doing a DDL statement: I was trying to create new Tables, which
              is a definite "no-go"
              - pay careful attention to:
              http://edocs.bea.com/wls/docs60/jta/trxejb.html#1051405
                        and
              http://edocs.bea.com/wls/docs60/jta/trxejb.html#1051741
              and use these Settings for the Pool, don't ask me why, but it took me
              hours to find it out by myself:
                   <JDBCConnectionPool CapacityIncrement="5"
              DriverName="weblogic.jdbc.oci.xa.XADataSource" InitialCapacity="1"
              LoginDelaySeconds="1" MaxCapacity="2" Name="oracleSecurityPool"
              Properties="user=xxx; password=xxx; server=xxx.xxx.xxx"
              RefreshMinutes="5" Targets="fbsserver" TestConnectionsOnRelease="true"
              TestTableName="Users" SupportsLocalTransaction="true"/>
              where as the server (shown as: xxx.xxx.xxx) is the TNS Name of the
              Oracle Driver.
              It works great.
              Another thing you guys might want to do is write a simple StatelessSB
              which does JDBC calls and two different database Connections.
              Then write a UnitTest which calls this bean a couple hundred times (with
              the same transaction). Have one test do clean writes, and another which
              causes some SQL-Exception (too long Data Columns, or likewise).
              Always count the entries and see if everything worked out. We're using
              this SetupConstruction to test new combinations of AS(sorry Priscilla) /
              Database / Db-Drivers to have a "standard test".
              I know my two cents were uncalled for, but it might save you some
              time.....
              thanx for your help
              Stefan
              -----Ursprüngliche Nachricht-----
              Von: Priscilla Fung [mailto:[email protected]]
              Bereitgestellt: Donnerstag, 2. August 2001 21:42
              Bereitgestellt in: transaction
              Unterhaltung: Two phase commit and bean managed transactions
              Betreff: Re: Two phase commit and bean managed transactions
              Hi Stefan,
              Looks like you have not actually begun a transaction by calling
              UserTransaction.begin(),
              so your setupTables method is really executing with no transaction
              context.
              Priscilla
              Stefan Siprell <[email protected]> wrote:
              >To all the Transaction GURUS!
              >
              >Hi guys (-and gals).
              >I've been doing J2EE for quite a while, but today was my first at
              >XA-Transactions and Bean Managed Transactions.
              >
              >Why am I doing this?
              >====================
              >Well I have to be able to controll the transactionalbehaviour of my
              >bean
              >during runtime, since some bean calls would cause a transactional
              >overflow due to the stress they would cause to the system, whereas
              >smaller bean calls need to run in one transaction.
              >-> Therefore I need Bean Managed Transactions
              >Since the bean does a call on two Database Connections it has to use
              >a
              >XA-Transaction.
              >-> Therefore I need XA-Transactions.
              >
              >Abstract
              >========
              >- I just can't get a User TransAction into the right Status it stays
              >in 'STATUS_NO_TRANSACTION' all the time
              >- Therefore the SQL Commands can be comitted 'java.sql.SQLException:
              >Does not support SQL execution with no global transaction'
              >- Therefore I can't do a rollback 'java.lang.IllegalStateException:
              >Transaction does not exist'
              >- Therefore I wrote this mail.
              >
              >I don't want to be a smart-"ass" writing such a detailed and indepth
              >mail. I just would like to show that I tried, and would like to have
              >some replies from you guys.
              >
              >Below are my configurations, code and logfiles.
              >
              >Thanx for taking your time and hope that the other people may learn
              >something as well.
              >
              >cu
              >
              >Stefan
              >
              >
              >Scenario
              >========
              >
              >used Software
              >-------------
              >Bea Weblogic (WL) 6.0 SPx (not real sure which SP i have)
              >Oracle 8.1.6 using the API-Version 8
              >
              >
              >I configured the system as follows:
              >(ofcourse I 'xxx'ed out all of the confidential data, sorry guys;-))
              >excerpt from:
              >
              >config.xml
              >----------
              ><JDBCConnectionPool CapacityIncrement="5"
              >DriverName="oracle.jdbc.driver.OracleDriver" InitialCapacity="2"
              >LoginDelaySeconds="1" MaxCapacity="5" Name="oraclePool"
              >Properties="user=xxx;password=xxx;dll=ocijdbc8;protocol=thin"
              >RefreshMinutes="5" Targets="fbsserver" TestConnectionsOnRelease="true"
              >TestTableName="languages" URL="jdbc:oracle:thin:@xxx:1521:xxx "/>
              >
              ><!-- Since this is our Main Datasource I would not like to use a XA
              >Transaction due to performance Issues
              >and the TxDataSource:
              >-->
              >
              ><JDBCTxDataSource EnableTwoPhaseCommit="true"
              >JNDIName="finstral.datasource.fbs" Name="finstral Content Datasource"
              >PoolName="oraclePool" Targets="fbsserver"/>
              >
              ><!-- no comment required -I hope.
              >Next comes the "special" Pool
              >-->
              >
              ><JDBCConnectionPool CapacityIncrement="5"
              >DriverName="weblogic.jdbc.oci.xa.XADataSource" InitialCapacity="1"
              >LoginDelaySeconds="1" MaxCapacity="2" Name="oracleSecurityPool"
              >Properties="user=xxx;password=xxx;server=xxx.xxx.xxx"
              >RefreshMinutes="5" Targets="fbsserver" TestConnectionsOnRelease="true"
              >TestTableName="Users" SupportsLocalTransaction="true"/>
              >
              ><!-- Well since there can only be one none XARessourceManager involved
              >in a 2PC
              >(keyword: Two Phase Commit) I will have to use a XACapable Driver for
              >the other
              >Datasource. Due to all the bugs in the oracle.xxx driver. I'll be
              >using the jdriver for oci.
              >I activated 'SupportsLocalTransaction' hoping it would solve my
              >problem - without effect. I just left in there now, since it made
              >sense me. Not?
              >Again the TxDataSource:
              >-->
              >
              ><JDBCTxDataSource EnableTwoPhaseCommit="true"
              >JNDIName="finstral.datasource.fbssecurity" Name="finstral Security
              >Datasource" PoolName="oracleSecurityPool" Targets="fbsserver"/>
              >
              ><!-- The System starts right up and can locate the test tables and
              >everything. So I think all of this stuff is working here -->
              >
              >
              >
              >ejb-jar.xml
              >-----------
              ><ejb-jar>
              >     <enterprise-beans>
              >          <session>
              >               <ejb-name>TPCTestBean</ejb-name>
              >     
              ><home>de.sitewaerts.futuna.common.test.tpcbean.TPCHome</home>
              >     
              ><remote>de.sitewaerts.futuna.common.test.tpcbean.TPC</remote>
              >     
              ><ejb-class>de.sitewaerts.futuna.common.test.tpcbean.TPCBean</ejb-class>
              >               <session-type>Stateless</session-type>
              >               <transaction-type>Bean</transaction-type>
              >          </session>
              >     </enterprise-beans>
              >     <assembly-descriptor/>
              ></ejb-jar>
              >
              ><!-- Originally I had the assembly-descriptor full of transaction
              >requirements. I thought since
              >the bean is handling all of the transaction stuff itself, it might get
              >confused by the 'container-transaction'
              >properties, and deleted them. Do I need them anyway?-->
              >
              >weblogic-ejb-jar.xml
              >--------------------
              ><weblogic-ejb-jar>
              >     <weblogic-enterprise-bean>
              >          <ejb-name>TPCTestBean</ejb-name>
              >          <stateless-session-descriptor/>
              >          <jndi-name>finstral/ejb/test_tpc</jndi-name>
              >     </weblogic-enterprise-bean>
              ></weblogic-ejb-jar>
              >
              ><!-- Nothing I have to explain here -->
              >
              >BeanCode (from the implementingBeanClass:
              >'de.sitewaerts.futuna.common.test.tpcbean.TPCBean')
              >-----------------------------------------------------------------------
              >---------------------
              >
              > public void setupTables() throws RemoteException
              > {
              > UserTransaction tx = getTransaction();
              > //getTransaction calls: 'tx = sCtx.getUserTransaction()' and does
              >some errorhandling
              >
              > log.info("Die Transaktion vor den Connections: "+tx.toString());
              > //Sorry bout the German. You should get the Message though.
              > log.info("Der Transaktionsstatus vor den Connections:
              >"+transactionStatus(tx));
              >
              > Connection conSecurity = getConnection(DATASOURCE_SECURITY, tx);
              > //gets a Connection via a DataSourceName from the JNDI tree
              > Connection conContent = getConnection(DATASOURCE_CONTENT, tx);
              >
              > log.info("Die frische Connection conSecurity: "+conSecurity);
              > log.info("Die frische Connection conContent: "+conContent);
              >
              > tearDownTable(conSecurity);
              > //Does nothing special
              > tearDownTable(conContent);
              >
              > log.info("Die Transaktion nach dem Teardown: "+tx.toString());
              > log.info("Der Transaktionsstatus nach dem Teardown:
              >"+transactionStatus(tx));
              >
              > Statement stmt = null;
              > try
              > {
              > stmt = conSecurity.createStatement();
              > //Well its getting interesting now.....
              >
              > log.info("Die Transaktion vor dem createtable: "+tx.toString());
              > log.info("Der Transaktionsstatus vor dem createtable:
              >"+transactionStatus(tx));
              > log.info("Die Connection conSecurity vor dem createtable:
              >"+conSecurity);
              > log.info("Die Connection conContent vor dem createtable:
              >"+conContent);
              >
              > stmt.executeUpdate(CREATE_TABLE);
              > //above is the row 91 -> throws: 'java.sql.SQLException: Does
              >not support SQL execution with no global transaction'
              >
              > stmt.close();
              >
              > stmt = conContent.createStatement();
              > stmt.executeUpdate(CREATE_TABLE);
              > stmt.close();
              > commitTransaction(tx);
              > }
              > catch (SQLException sqle)
              > {
              > log.error("Konnte kein table init machen", sqle);
              > rollbackTransaction(tx);
              > //The Code for this method is below
              > throw new EJBException(sqle);
              > }
              > finally
              > {
              > closeConnection(conSecurity);
              > closeConnection(conContent);
              > }
              > }
              >
              > protected void rollbackTransaction(UserTransaction tx)
              > {
              > log.info("Der Transaktionsstatus vor dem Rollback:
              >"+transactionStatus(tx));
              > log.info("Die Transaktion vor dem Rollback: "+tx.toString());
              > try
              > {
              > tx.rollback();
              > //above is row 200 -> throws: 'java.lang.IllegalStateException:
              >Transaction does not exist'
              > log.info("Der Transaktionsstatus nach dem Rollback:
              >"+transactionStatus(tx));
              > log.info("Die Transaktion nach dem Rollback: "+tx.toString());
              > }
              > catch (Exception e)
              > {
              > log.error("Konnte die Transaktion nicht backrollen.", e);
              > throw new EJBException(e);
              > }
              > }
              >
              >Log Excerpt
              >===========
              >INFO setupTables() (66) - Die Transaktion vor den Connections:
              >[email protected]
              >INFO setupTables() (67) - Der Transaktionsstatus vor den Connections:
              >STATUS_NO_TRANSACTION
              >INFO setupTables() (72) - Die frische Connection conSecurity:
              >weblogic.jdbc.rmi.SerialConnection@7c6daa
              >INFO setupTables() (73) - Die frische Connection conContent:
              >weblogic.jdbc.rmi.SerialConnection@3b425
              >INFO setupTables() (78) - Die Transaktion nach dem Teardown:
              >[email protected]
              >INFO setupTables() (79) - Der Transaktionsstatus nach dem Teardown:
              >STATUS_NO_TRANSACTION
              >INFO setupTables() (86) - Die Transaktion vor dem createtable:
              >[email protected]
              >INFO setupTables() (87) - Der Transaktionsstatus vor dem createtable:
              >STATUS_NO_TRANSACTION
              >INFO setupTables() (88) - Die Connection conSecurity vor dem
              >createtable: weblogic.jdbc.rmi.SerialConnection@7c6daa
              >INFO setupTables() (89) - Die Connection conContent vor dem
              >createtable: weblogic.jdbc.rmi.SerialConnection@3b425
              >ERROR setupTables() (101) - Konnte kein table init machen
              >java.sql.SQLException: Does not support SQL execution with no global
              >transaction
              >     at
              >weblogic.jdbc.oci.xa.XAConnection.beforeExecute(XAConnection.java:137)
              >     at
              >weblogic.jdbc.oci.xa.Statement.executeUpdate(Statement.java:112)
              >     at weblogic.jdbc.jta.Statement.executeUpdate(Statement.java:185)
              >     at
              >weblogic.jdbc.rmi.internal.StatementImpl.executeUpdate(StatementImpl.ja
              v
              >a:42)
              >     at
              >weblogic.jdbc.rmi.SerialStatement.executeUpdate(SerialStatement.java:54
              >     at
              >de.sitewaerts.futuna.common.test.tpcbean.TPCBean.setupTables(TPCBean.ja
              v
              >a:91)
              >     at
              >de.sitewaerts.futuna.common.test.tpcbean.TPCBeanImpl.setupTables(TPCBea
              n
              >Impl.java:130)
              >     at
              >de.sitewaerts.futuna.common.test.tpcbean.TPCBeanEOImpl.setupTables(TPCB
              e
              >anEOImpl.java:64)
              >     at
              >de.sitewaerts.futuna.common.test.TwoPhaseCommitUnitTest.setUp(TwoPhaseC
              o
              >mmitUnitTest.java:51)
              >     at
              >org.apache.commons.cactus.AbstractTestCase.runBareServerTest(AbstractTe
              s
              >tCase.java:297)
              >     at
              >org.apache.commons.cactus.server.ServletTestCaller.callTestMethod(Servl
              e
              >tTestCaller.java:148)
              >     at
              >org.apache.commons.cactus.server.ServletTestCaller.doTest(ServletTestCa
              l
              >ler.java:199)
              >     at
              >org.apache.commons.cactus.server.ServletTestRedirector.doPost(ServletTe
              s
              >tRedirector.java:149)
              >     at javax.servlet.http.HttpServlet.service(HttpServlet.java:760)
              >     at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
              >     at
              >weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl
              >java:213)
              >     at
              >weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppServ
              l
              >etContext.java:1265)
              >     at
              >weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestImpl
              >java:1631)
              >     at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:137)
              >     at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:120)
              >INFO rollbackTransaction() (196) - Der Transaktionsstatus vor dem
              >Rollback: STATUS_NO_TRANSACTION
              >INFO rollbackTransaction() (197) - Die Transaktion vor dem Rollback:
              >[email protected]
              >ERROR rollbackTransaction() (206) - Konnte die Transaktion nicht
              >backrollen.
              >java.lang.IllegalStateException: Transaction does not exist
              >     at
              >weblogic.transaction.internal.TransactionManagerImpl.rollback(Transacti
              o
              >nManagerImpl.java:228)
              >     at
              >weblogic.transaction.internal.TransactionManagerImpl.rollback(Transacti
              o
              >nManagerImpl.java:222)
              >     at
              >de.sitewaerts.futuna.common.test.tpcbean.TPCBean.rollbackTransaction(TP
              C
              >Bean.java:200)
              >     at
              >de.sitewaerts.futuna.common.test.tpcbean.TPCBean.setupTables(TPCBean.ja
              v
              >a:102)
              >     at
              >de.sitewaerts.futuna.common.test.tpcbean.TPCBeanImpl.setupTables(TPCBea
              n
              >Impl.java:130)
              >     at
              >de.sitewaerts.futuna.common.test.tpcbean.TPCBeanEOImpl.setupTables(TPCB
              e
              >anEOImpl.java:64)
              >     at
              >de.sitewaerts.futuna.common.test.TwoPhaseCommitUnitTest.setUp(TwoPhaseC
              o
              >mmitUnitTest.java:51)
              >     at
              >org.apache.commons.cactus.AbstractTestCase.runBareServerTest(AbstractTe
              s
              >tCase.java:297)
              >     at
              >org.apache.commons.cactus.server.ServletTestCaller.callTestMethod(Servl
              e
              >tTestCaller.java:148)
              >     at
              >org.apache.commons.cactus.server.ServletTestCaller.doTest(ServletTestCa
              l
              >ler.java:199)
              >     at
              >org.apache.commons.cactus.server.ServletTestRedirector.doPost(ServletTe
              s
              >tRedirector.java:149)
              >     at javax.servlet.http.HttpServlet.service(HttpServlet.java:760)
              >     at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
              >     at
              >weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl
              >java:213)
              >     at
              >weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppServ
              l
              >etContext.java:1265)
              >     at
              >weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestImpl
              >java:1631)
              >     at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:137)
              >     at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:120)
              >
              >
              >CONCLUSION
              >==========
              >I'm going nuts.
              >I just don't get it.
              >The transaction is the same. I don't change the Connection. I start
              >the Transaction at the beginning before I do anything!
              >Please guys help me out.
              >Thx alot.
              >
              >Stefan "it's three o'clock in the morning, my girlfriend left me, and
              >my only friend is that stupid linux pinguine" Siprell
              >Software-Development
              ><<<<<<<<<<<<<<<<<<<<<<<<<<<
              ><sitewaerts> GmbH
              >Hebelstraße 15
              >D-76131 Karlsruhe
              >
              >Tel: +49 (721) 920 918 22
              >Fax: +49 (721) 920 918 29
              >http://www.sitewaerts.de
              >>>>>>>>>>>>>>>>>>>>>>>>>>>>
              >
              >
              >
              

  • Doubts on nonxa oracle datasources in Weblogic JTA transaction

    I am doing some studying on XA transaction handling in weblogic 10.3.6. I read a lot materials on web saying that can't enlist more than 1 non xa datasources inside one single XA transaction, so I am doing a simple test: trying to update one record in one oracle database, and inserting one record in another.
    The test code is below:
    @Stateless(mappedName = "nativeQueryTest")
    @TransactionManagement(TransactionManagementType.CONTAINER)
    @TransactionAttribute(TransactionAttributeType.REQUIRED)
    public class DaoEjb implements .... {
         @PersistenceContext(unitName="nonxa.unit")
         private EntityManager nonXAPC;
         @PersistenceContext(unitName="another.nonxa.unit")
         private EntityManager anotherNonXAPC;
         @Override
         public void doUpdateWithNonXaDss() {
              Employee l_entity = nonXAPC.find(Employee.class, "tom");
              l_entity.setAge(new Random().nextInt());
              Department l_dep = new Department();
              l_dep.setName("dept" + new Random().nextInt());
              l_dep.setEmployeeNum(new Random().nextInt());
              anotherNonXAPC.persist(l_dep);
    The persistence unit definitions are:
         <persistence-unit name="nonxa.unit" transaction-type="JTA">
              <provider>org.eclipse.persistence.jpa.PersistenceProvider</provider>
              <jta-data-source>nonxa.ds</jta-data-source>
              <class>entity.Employee</class>
              <exclude-unlisted-classes>true</exclude-unlisted-classes>
              <properties>
                   <property name="eclipselink.target-database" value="Oracle" />
    <property name="eclipselink.jdbc.batch-writing" value="Oracle-JDBC" />
    <property name="eclipselink.target-server" value="WebLogic_10" />
                   <property name="eclipselink.logging.parameters" value="true" />
                   <property name="eclipselink.logging.logger" value="ServerLogger" />
              </properties>
         </persistence-unit>
         <persistence-unit name="another.nonxa.unit" transaction-type="JTA">
              <provider>org.eclipse.persistence.jpa.PersistenceProvider</provider>
              <jta-data-source>another.nonxa.ds</jta-data-source>
              <class>entity.Department</class>
              <exclude-unlisted-classes>true</exclude-unlisted-classes>
              <properties>
                   <property name="eclipselink.target-database" value="Oracle" />
                   <property name="eclipselink.jdbc.batch-writing" value="Oracle-JDBC" />
                   <property name="eclipselink.target-server" value="WebLogic_10" />
                   <property name="eclipselink.logging.parameters" value="true" />
                   <property name="eclipselink.logging.logger" value="ServerLogger" />
              </properties>
         </persistence-unit>
    For the two data sources, they are pointed to two different oracle databases on two different physical servers. I use "oracle.jdbc.OracleDriver" as the drivers, and also make sure that "Support Global Transaction" options un-selected.
    I used a simple client to invoke the EJB, and saw the method completes without any error: the first record is updated and second record is inserted! Therefore I am really confused:
    1) is the JTA transaction XA or not in my small EJB?
    2) if it's XA, why can I use two non-XA datasources inside this XA transaction?

    Why do you think this should fail? Looks to me like you have two isolated transactions going on that have no relation to each other.

  • JTA transaction unexpectedly rolled back

    I have a Spring Java web app deployed on OC4J 10.1.3.3 using Toplink as the container managed persistence. When my app is launched a named query is executed that uses JPQL to load up collections of objects. It is failing with the subject line exception.
    org.springframework.transaction.UnexpectedRollbackException: JTA transaction unexpectedly rolled back (maybe due to a timeout); nested exception is javax.transaction.RollbackException: Timed out
    If, however, I then modify the URL and force an action that will re-execute the same query, it works fine.
    Any ideas on which configuration settings I should investigage/change to enable this to work the first time through?
    I am not dealing with large collections here. At this point, there are 11 main objects that have children/parents. Re-execution of the query happens very fast.
    Thank you!
    Ginni

    Hello,
    It sounds like its not the query itself that is taking too long, but all the processing done before the query in the same transaction scope. The error is that the transaction is timing out, so you should start by checking when the transaction is started and if the timeout value needs to be increased to cover the time this process is taking, or if the transaction can be made smaller or broken up into smaller peices. Or, if the query is just returning data that isn't going to be modified, if a transaction is required at all.
    Best Regards,
    Chris

  • SAP J2EE Engine JTA Transaction Xml for table TABLE could not be ana

    I'm having a weird case. I created 3 entity bean. In my R/3 will call this JCO.Function to do the insert to database. But out of 3 entity bean, only 1 entity bean got error where it unable to insert to database and have this error in the log.
    The case is quite weird where i created the same entity but only 1 entity is not working as expected. Wondering what cause this problem.
    Thanks.
    org.xml.sax.SAXException: Fatal Error: URI=:main: Line=1: Fatal Error: com.sap.engine.lib.xml.parser.ParserException: Name expected: 0x20(:main:, row:1, col:218)#
    at com.sap.dictionary.database.dbs.XmlExtractor$XMLErrorHandler.fatalError(XmlExtractor.java:279)#
    at com.sap.engine.lib.xml.parser.SAXParser.parse(SAXParser.java:144)#
    at com.sap.dictionary.database.dbs.XmlExtractor.map(XmlExtractor.java:130)#
    at com.sap.dictionary.database.catalog.DbGeneralStructure.<init>(DbGeneralStructure.java:86)#
    at com.sap.dictionary.database.catalog.XmlCatalogReader.getTable(XmlCatalogReader.java:90)#
    at com.sap.sql.catalog.impl.BufferedCatalogReader.getTable(BufferedCatalogReader.java:124)#
    at com.sap.sql.catalog.impl.BufferedCatalogReader.getTable(BufferedCatalogReader.java:87)#
    at com.sap.sql.sqlparser.CheckColAndTabVisitor.checkTables(CheckColAndTabVisitor.java:299)#
    at com.sap.sql.sqlparser.CheckColAndTabVisitor.performCatalogChecks(CheckColAndTabVisitor.java:176)#
    at com.sap.sql.sqlparser.CommonSQLStatement.checkSemantics(CommonSQLStatement.java:169)#
    at com.sap.sql.jdbc.common.StatementAnalyzerImpl.check(StatementAnalyzerImpl.java:35)#
    at com.sap.sql.jdbc.common.StatementAnalyzerImpl.preprepareStatement(StatementAnalyzerImpl.java:101)#
    at com.sap.sql.jdbc.common.StatementAnalyzerImpl.preprepareStatement(StatementAnalyzerImpl.java:87)#
    at com.sap.sql.jdbc.common.AbstractCommonStatement.parseStatement(AbstractCommonStatement.java:472)#
    at com.sap.sql.jdbc.common.CommonConnectionImpl.prepareStatement(CommonConnectionImpl.java:375)#
    at com.sap.engine.services.dbpool.cci.ConnectionHandle.prepareStatement(ConnectionHandle.java:81)#
    at net.tnb.model.ReasonCodeEntityBean3_0Persistent.ejb_iInsert(ReasonCodeEntityBean3_0Persistent.java:306)#
    at com.sap.engine.services.ejb.entity.pm.UpdatablePersistent.ejbFlush(UpdatablePersistent.java:92)#
    at com.sap.engine.services.ejb.entity.pm.TransactionContext.flushAll(TransactionContext.java:429)#
    at com.sap.engine.services.ejb.entity.pm.TransactionContext.flush(TransactionContext.java:378)#
    at com.sap.engine.services.ejb.entity.pm.TransactionContext.beforeCompletion(TransactionContext.java:506)#
    at com.sap.engine.services.ejb.entity.SynchronizationList.beforeCompletion(SynchronizationList.java:136)#
    at com.sap.engine.services.ts.jta.impl.TransactionImpl.commit(TransactionImpl.java:226)#
    at net.tnb.model.ReasonCodeEntityHomeImpl3_0.create(ReasonCodeEntityHomeImpl3_0.java:546)#
    at net.tnb.model.ReasonCodeEntityHome_Stub.create(ReasonCodeEntityHome_Stub.java:57)#
    at net.tnb.model.EToGatewayBean.insertIntoTable(EToGatewayBean.java:223)#
    at net.tnb.model.EToGatewayBean.processFunction(EToGatewayBean.java:166)#
    at net.tnb.model.EToGatewayLocalLocalObjectImpl3_0.processFunction(EToGatewayLocalLocalObjectImpl3_0.java:175)#
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)#
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)#
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)#
    at java.lang.reflect.Method.invoke(Method.java:324)#
    at com.sap.engine.services.rfcengine.RFCDefaultRequestHandler.call(RFCDefaultRequestHandler.java:277)#
    at com.sap.engine.services.rfcengine.RFCDefaultRequestHandler.handleRequest(RFCDefaultRequestHandler.java:219)#
    at com.sap.engine.services.rfcengine.RFCJCOServer$J2EEApplicationRunnable.run(RFCJCOServer.java:260)#
    at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:37)#
    at java.security.AccessController.doPrivileged(Native Method)#
    at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.java:100)#
    at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:170)#
    ##0#0#Error##Java###{0}.commit(), Cannot commit due to unexpected exception in beforeCompletion(): 
    [EXCEPTION]
    {1}#2#SAP J2EE Engine JTA Transaction : [031fffffff3ffffffb2005b]#java.lang.IllegalStateException: Xml for table <TABLE> could not be analysed
         at com.sap.dictionary.database.catalog.XmlCatalogReader.getTable(XmlCatalogReader.java:100)
         at com.sap.sql.catalog.impl.BufferedCatalogReader.getTable(BufferedCatalogReader.java:124)
         at com.sap.sql.catalog.impl.BufferedCatalogReader.getTable(BufferedCatalogReader.java:87)
         at com.sap.sql.sqlparser.CheckColAndTabVisitor.checkTables(CheckColAndTabVisitor.java:299)
         at com.sap.sql.sqlparser.CheckColAndTabVisitor.performCatalogChecks(CheckColAndTabVisitor.java:176)
         at com.sap.sql.sqlparser.CommonSQLStatement.checkSemantics(CommonSQLStatement.java:169)
         at com.sap.sql.jdbc.common.StatementAnalyzerImpl.check(StatementAnalyzerImpl.java:35)
         at com.sap.sql.jdbc.common.StatementAnalyzerImpl.preprepareStatement(StatementAnalyzerImpl.java:101)
         at com.sap.sql.jdbc.common.StatementAnalyzerImpl.preprepareStatement(StatementAnalyzerImpl.java:87)
         at com.sap.sql.jdbc.common.AbstractCommonStatement.parseStatement(AbstractCommonStatement.java:472)
         at com.sap.sql.jdbc.common.CommonConnectionImpl.prepareStatement(CommonConnectionImpl.java:375)
         at com.sap.engine.services.dbpool.cci.ConnectionHandle.prepareStatement(ConnectionHandle.java:81)
         at net.tnb.model.ReasonCodeEntityBean3_0Persistent.ejb_iInsert(ReasonCodeEntityBean3_0Persistent.java:306)
         at com.sap.engine.services.ejb.entity.pm.UpdatablePersistent.ejbFlush(UpdatablePersistent.java:92)
         at com.sap.engine.services.ejb.entity.pm.TransactionContext.flushAll(TransactionContext.java:429)
         at com.sap.engine.services.ejb.entity.pm.TransactionContext.flush(TransactionContext.java:378)
         at com.sap.engine.services.ejb.entity.pm.TransactionContext.beforeCompletion(TransactionContext.java:506)
         at com.sap.engine.services.ejb.entity.SynchronizationList.beforeCompletion(SynchronizationList.java:136)
         at com.sap.engine.services.ts.jta.impl.TransactionImpl.commit(TransactionImpl.java:226)
         at net.tnb.model.ReasonCodeEntityHomeImpl3_0.create(ReasonCodeEntityHomeImpl3_0.java:546)
         at net.tnb.model.ReasonCodeEntityHome_Stub.create(ReasonCodeEntityHome_Stub.java:57)
         at net.tnb.model.EToGatewayBean.insertIntoTable(EToGatewayBean.java:223)
         at net.tnb.model.EToGatewayBean.processFunction(EToGatewayBean.java:166)
         at net.tnb.model.EToGatewayLocalLocalObjectImpl3_0.processFunction(EToGatewayLocalLocalObjectImpl3_0.java:175)
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:324)
         at com.sap.engine.services.rfcengine.RFCDefaultRequestHandler.call(RFCDefaultRequestHandler.java:277)
         at com.sap.engine.services.rfcengine.RFCDefaultRequestHandler.handleRequest(RFCDefaultRequestHandler.java:219)
         at com.sap.engine.services.rfcengine.RFCJCOServer$J2EEApplicationRunnable.run(RFCJCOServer.java:260)
         at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:37)
         at java.security.AccessController.doPrivileged(Native Method)
         at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.java:100)
         at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:170)
    #1.5 #001A6467CDF400590000004E000018D8000459BB785F496C#1224561620123#com.sap.engine.services.ts#sap.com/ESolutionsEGatewayEAR#com.sap.engine.services.ts#J2EE_GUEST#0####95b74d409f2411dd86c4001a6467cdf4#SAPEngine_Application_Thread[impl:3]_20##0#0#Error#1#/System/Server#Java#ts_0004##Exception in beforeCompletition of ( SAP J2EE Engine JTA Transaction : [031fffffff3ffffffb2005b] ).#1#SAP J2EE Engine JTA Transaction : [031fffffff3ffffffb2005b]#
    #1.5 #001A6467CDF400590000004F000018D8000459BB785F4BC5#1224561620123#com.sap.engine.services.ts#sap.com/ESolutionsEGatewayEAR#com.sap.engine.services.ts#J2EE_GUEST#0####95b74d409f2411dd86c4001a6467cdf4#SAPEngine_Application_Thread[impl:3]_20##0#0#Error#1#/System/Audit#Java###Exception {0}#1#com.sap.engine.services.ts.exceptions.BaseRollbackException: Exception in beforeCompletition of ( SAP J2EE Engine JTA Transaction : [031fffffff3ffffffb2005b] ).
         at com.sap.engine.services.ts.jta.impl.TransactionImpl.commit(TransactionImpl.java:236)
         at net.tnb.model.ReasonCodeEntityHomeImpl3_0.create(ReasonCodeEntityHomeImpl3_0.java:546)
         at net.tnb.model.ReasonCodeEntityHome_Stub.create(ReasonCodeEntityHome_Stub.java:57)
         at net.tnb.model.EToGatewayBean.insertIntoTable(EToGatewayBean.java:223)
         at net.tnb.model.EToGatewayBean.processFunction(EToGatewayBean.java:166)
         at net.tnb.model.EToGatewayLocalLocalObjectImpl3_0.processFunction(EToGatewayLocalLocalObjectImpl3_0.java:175)
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:324)
         at com.sap.engine.services.rfcengine.RFCDefaultRequestHandler.call(RFCDefaultRequestHandler.java:277)
         at com.sap.engine.services.rfcengine.RFCDefaultRequestHandler.handleRequest(RFCDefaultRequestHandler.java:219)
         at com.sap.engine.services.rfcengine.RFCJCOServer$J2EEApplicationRunnable.run(RFCJCOServer.java:260)
         at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:37)
         at java.security.AccessController.doPrivileged(Native Method)
         at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.java:100)
         at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:170)
    Caused by: java.lang.IllegalStateException: Xml for table ZREASON_CODE could not be analysed
         at com.sap.dictionary.database.catalog.XmlCatalogReader.getTable(XmlCatalogReader.java:100)
         at com.sap.sql.catalog.impl.BufferedCatalogReader.getTable(BufferedCatalogReader.java:124)
         at com.sap.sql.catalog.impl.BufferedCatalogReader.getTable(BufferedCatalogReader.java:87)
         at com.sap.sql.sqlparser.CheckColAndTabVisitor.checkTables(CheckColAndTabVisitor.java:299)
         at com.sap.sql.sqlparser.CheckColAndTabVisitor.performCatalogChecks(CheckColAndTabVisitor.java:176)
         at com.sap.sql.sqlparser.CommonSQLStatement.checkSemantics(CommonSQLStatement.java:169)
         at com.sap.sql.jdbc.common.StatementAnalyzerImpl.check(StatementAnalyzerImpl.java:35)
         at com.sap.sql.jdbc.common.StatementAnalyzerImpl.preprepareStatement(StatementAnalyzerImpl.java:101)
         at com.sap.sql.jdbc.common.StatementAnalyzerImpl.preprepareStatement(StatementAnalyzerImpl.java:87)
         at com.sap.sql.jdbc.common.AbstractCommonStatement.parseStatement(AbstractCommonStatement.java:472)
         at com.sap.sql.jdbc.common.CommonConnectionImpl.prepareStatement(CommonConnectionImpl.java:375)
         at com.sap.engine.services.dbpool.cci.ConnectionHandle.prepareStatement(ConnectionHandle.java:81)
         at net.tnb.model.ReasonCodeEntityBean3_0Persistent.ejb_iInsert(ReasonCodeEntityBean3_0Persistent.java:306)
         at com.sap.engine.services.ejb.entity.pm.UpdatablePersistent.ejbFlush(UpdatablePersistent.java:92)
         at com.sap.engine.services.ejb.entity.pm.TransactionContext.flushAll(TransactionContext.java:429)
         at com.sap.engine.services.ejb.entity.pm.TransactionContext.flush(TransactionContext.java:378)
         at com.sap.engine.services.ejb.entity.pm.TransactionContext.beforeCompletion(TransactionContext.java:506)
         at com.sap.engine.services.ejb.entity.SynchronizationList.beforeCompletion(SynchronizationList.java:136)
         at com.sap.engine.services.ts.jta.impl.TransactionImpl.commit(TransactionImpl.java:226)
         ... 16 more
    #1.5 #001A6467CDF4005900000050000018D8000459BB785F4E8F#1224561620123#com.sap.engine.services.ejb.entity.Container#sap.com/ESolutionsEGatewayEAR#com.sap.engine.services.ejb.entity.Container#J2EE_GUEST#0####95b74d409f2411dd86c4001a6467cdf4#SAPEngine_Application_Thread[impl:3]_20##0#0#Error##Java###null
    [EXCEPTION]
    {0}#1#com.sap.engine.services.ejb.exceptions.BaseRemoteException: Transaction system failure in method net.tnb.model.ReasonCodeEntityHomeImpl3_0.create(net.tnb.model.ReasonCodeBean).
         at net.tnb.model.ReasonCodeEntityHomeImpl3_0.create(ReasonCodeEntityHomeImpl3_0.java:573)
         at net.tnb.model.ReasonCodeEntityHome_Stub.create(ReasonCodeEntityHome_Stub.java:57)
         at net.tnb.model.EToGatewayBean.insertIntoTable(EToGatewayBean.java:223)
         at net.tnb.model.EToGatewayBean.processFunction(EToGatewayBean.java:166)
         at net.tnb.model.EToGatewayLocalLocalObjectImpl3_0.processFunction(EToGatewayLocalLocalObjectImpl3_0.java:175)
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:324)
         at com.sap.engine.services.rfcengine.RFCDefaultRequestHandler.call(RFCDefaultRequestHandler.java:277)
         at com.sap.engine.services.rfcengine.RFCDefaultRequestHandler.handleRequest(RFCDefaultRequestHandler.java:219)
         at com.sap.engine.services.rfcengine.RFCJCOServer$J2EEApplicationRunnable.run(RFCJCOServer.java:260)
         at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:37)
         at java.security.AccessController.doPrivileged(Native Method)
         at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.java:100)
         at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:170)
    Caused by: com.sap.engine.services.ts.exceptions.BaseRollbackException: Exception in beforeCompletition of ( SAP J2EE Engine JTA Transaction : [031fffffff3ffffffb2005b] ).
         at com.sap.engine.services.ts.jta.impl.TransactionImpl.commit(TransactionImpl.java:236)
         at net.tnb.model.ReasonCodeEntityHomeImpl3_0.create(ReasonCodeEntityHomeImpl3_0.java:546)
         ... 15 more
    Caused by: java.lang.IllegalStateException: Xml for table ZREASON_CODE could not be analysed
         at com.sap.dictionary.database.catalog.XmlCatalogReader.getTable(XmlCatalogReader.java:100)
         at com.sap.sql.catalog.impl.BufferedCatalogReader.getTable(BufferedCatalogReader.java:124)
         at com.sap.sql.catalog.impl.BufferedCatalogReader.getTable(BufferedCatalogReader.java:87)
         at com.sap.sql.sqlparser.CheckColAndTabVisitor.checkTables(CheckColAndTabVisitor.java:299)
         at com.sap.sql.sqlparser.CheckColAndTabVisitor.performCatalogChecks(CheckColAndTabVisitor.java:176)
         at com.sap.sql.sqlparser.CommonSQLStatement.checkSemantics(CommonSQLStatement.java:169)
         at com.sap.sql.jdbc.common.StatementAnalyzerImpl.check(StatementAnalyzerImpl.java:35)
         at com.sap.sql.jdbc.common.StatementAnalyzerImpl.preprepareStatement(StatementAnalyzerImpl.java:101)
         at com.sap.sql.jdbc.common.StatementAnalyzerImpl.preprepareStatement(StatementAnalyzerImpl.java:87)
         at com.sap.sql.jdbc.common.AbstractCommonStatement.parseStatement(AbstractCommonStatement.java:472)
         at com.sap.sql.jdbc.common.CommonConnectionImpl.prepareStatement(CommonConnectionImpl.java:375)
         at com.sap.engine.services.dbpool.cci.ConnectionHandle.prepareStatement(ConnectionHandle.java:81)
         at net.tnb.model.ReasonCodeEntityBean3_0Persistent.ejb_iInsert(ReasonCodeEntityBean3_0Persistent.java:306)
         at com.sap.engine.services.ejb.entity.pm.UpdatablePersistent.ejbFlush(UpdatablePersistent.java:92)
         at com.sap.engine.services.ejb.entity.pm.TransactionContext.flushAll(TransactionContext.java:429)
         at com.sap.engine.services.ejb.entity.pm.TransactionContext.flush(TransactionContext.java:378)
         at com.sap.engine.services.ejb.entity.pm.TransactionContext.beforeCompletion(TransactionContext.java:506)
         at com.sap.engine.services.ejb.entity.SynchronizationList.beforeCompletion(SynchronizationList.java:136)
         at com.sap.engine.services.ts.jta.impl.TransactionImpl.commit(TransactionImpl.java:226)
         ... 16 more
    #1.5 #001A6467CDF4005900000051000018D8000459BB785F5FA9#1224561620123#System.err#sap.com/ESolutionsEGatewayEAR#System.err#J2EE_GUEST#0####95b74d409f2411dd86c4001a6467cdf4#SAPEngine_Application_Thread[impl:3]_20##0#0#Error##Plain###RemoteException insertOk=false#
    #1.5 #001A6467CDF4005900000052000018D8000459BB785F6094#1224561620123#System.err#sap.com/ESolutionsEGatewayEAR#System.err#J2EE_GUEST#0####95b74d409f2411dd86c4001a6467cdf4#SAPEngine_Application_Thread[impl:3]_20##0#0#Error##Plain###Tue Oct 21 12:00:20 SGT 2008 java.rmi.RemoteException: com.sap.engine.services.ejb.exceptions.BaseRemoteException: Transaction system failure in method net.tnb.model.ReasonCodeEntityHomeImpl3_0.create(net.tnb.model.ReasonCodeBean).
         at net.tnb.model.ReasonCodeEntityHomeImpl3_0.create(ReasonCodeEntityHomeImpl3_0.java:573)
         at net.tnb.model.ReasonCodeEntityHome_Stub.create(ReasonCodeEntityHome_Stub.java:57)
         at net.tnb.model.EToGatewayBean.insertIntoTable(EToGatewayBean.java:223)
         at net.tnb.model.EToGatewayBean.processFunction(EToGatewayBean.java:166)
         at net.tnb.model.EToGatewayLocalLocalObjectImpl3_0.processFunction(EToGatewayLocalLocalObjectImpl3_0.java:175)
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:324)
         at com.sap.engine.services.rfcengine.RFCDefaultRequestHandler.call(RFCDefaultRequestHandler.java:277)
         at com.sap.engine.services.rfcengine.RFCDefaultRequestHandler.handleRequest(RFCDefaultRequestHandler.java:219)
         at com.sap.engine.services.rfcengine.RFCJCOServer$J2EEApplicationRunnable.run(RFCJCOServer.java:260)
         at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:37)
         at java.security.AccessController.doPrivileged(Native Method)
         at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.java:100)
         at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:170)
    Caused by: com.sap.engine.services.ts.exceptions.BaseRollbackException: Exception in beforeCompletition of ( SAP J2EE Engine JTA Transaction : [031fffffff3ffffffb2005b] ).
         at com.sap.engine.services.ts.jta.impl.TransactionImpl.commit(TransactionImpl.java:236)
         at net.tnb.model.ReasonCodeEntityHomeImpl3_0.create(ReasonCodeEntityHomeImpl3_0.java:546)
         ... 15 more
    Caused by: java.lang.IllegalStateException: Xml for table <TABLE> could not be analysed
         at com.sap.dictionary.database.catalog.XmlCatalogReader.getTable(XmlCatalogReader.java:100)
         at com.sap.sql.catalog.impl.BufferedCatalogReader.getTable(BufferedCatalogReader.java:124)
         at com.sap.sql.catalog.impl.BufferedCatalogReader.getTable(BufferedCatalogReader.java:87)
         at com.sap.sql.sqlparser.CheckColAndTabVisitor.checkTables(CheckColAndTabVisitor.java:299)
         at com.sap.sql.sqlparser.CheckColAndTabVisitor.performCatalogChecks(CheckColAndTabVisitor.java:176)
         at com.sap.sql.sqlparser.CommonSQLStatement.checkSemantics(CommonSQLStatement.java:169)
         at com.sap.sql.jdbc.common.StatementAnalyzerImpl.check(StatementAnalyzerImpl.java:35)
         at com.sap.sql.jdbc.common.StatementAnalyzerImpl.preprepareStatement(StatementAnalyzerImpl.java:101)
         at com.sap.sql.jdbc.common.StatementAnalyzerImpl.preprepareStatement(StatementAnalyzerImpl.java:87)
         at com.sap.sql.jdbc.common.AbstractCommonStatement.parseStatement(AbstractCommonStatement.java:472)
         at com.sap.sql.jdbc.common.CommonConnectionImpl.prepareStatement(CommonConnectionImpl.java:375)
         at com.sap.engine.services.dbpool.cci.ConnectionHandle.prepareStatement(ConnectionHandle.java:81)
         at net.tnb.model.ReasonCodeEntityBean3_0Persistent.ejb_iInsert(ReasonCodeEntityBean3_0Persistent.java:306)
         at com.sap.engine.services.ejb.entity.pm.UpdatablePersistent.ejbFlush(UpdatablePersistent.java:92)
         at com.sap.engine.services.ejb.entity.pm.TransactionContext.flushAll(TransactionContext.java:429)
         at com.sap.engine.services.ejb.entity.pm.TransactionContext.flush(TransactionContext.java:378)
         at com.sap.engine.services.ejb.entity.pm.TransactionContext.beforeCompletion(TransactionContext.java:506)
         at com.sap.engine.services.ejb.entity.SynchronizationList.beforeCompletion(SynchronizationList.java:136)
         at com.sap.engine.services.ts.jta.impl.TransactionImpl.commit(TransactionImpl.java:226)
         ... 16 more
    ; nested exception is:
         javax.transaction.RollbackException: com.sap.engine.services.ts.exceptions.BaseRollbackException: Exception in beforeCompletition of ( SAP J2EE Engine JTA Transaction : [031fffffff3ffffffb2005b] ).
         at com.sap.engine.services.ts.jta.impl.TransactionImpl.commit(TransactionImpl.java:236)
         at net.tnb.model.ReasonCodeEntityHomeImpl3_0.create(ReasonCodeEntityHomeImpl3_0.java:546)
         at net.tnb.model.ReasonCodeEntityHome_Stub.create(ReasonCodeEntityHome_Stub.java:57)
         at net.tnb.model.EToGatewayBean.insertIntoTable(EToGatewayBean.java:223)
         at net.tnb.model.EToGatewayBean.processFunction(EToGatewayBean.java:166)
         at net.tnb.model.EToGatewayLocalLocalObjectImpl3_0.processFunction(EToGatewayLocalLocalObjectImpl3_0.java:175)
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:324)
         at com.sap.engine.services.rfcengine.RFCDefaultRequestHandler.call(RFCDefaultRequestHandler.java:277)
         at com.sap.engine.services.rfcengine.RFCDefaultRequestHandler.handleRequest(RFCDefaultRequestHandler.java:219)
         at com.sap.engine.services.rfcengine.RFCJCOServer$J2EEApplicationRunnable.run(RFCJCOServer.java:260)
         at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:37)
         at java.security.AccessController.doPrivileged(Native Method)
         at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.java:100)
         at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:170)
    Caused by: java.lang.IllegalStateException: Xml for table ZREASON_CODE could not be analysed
         at com.sap.dictionary.database.catalog.XmlCatalogReader.getTable(XmlCatalogReader.java:100)
         at com.sap.sql.catalog.impl.BufferedCatalogReader.getTable(BufferedCatalogReader.java:124)
         at com.sap.sql.catalog.impl.BufferedCatalogReader.getTable(BufferedCatalogReader.java:87)
         at com.sap.sql.sqlparser.CheckColAndTabVisitor.checkTables(CheckColAndTabVisitor.java:299)
         at com.sap.sql.sqlparser.CheckColAndTabVisitor.performCatalogChecks(CheckColAndTabVisitor.java:176)
         at com.sap.sql.sqlparser.CommonSQLStatement.checkSemantics(CommonSQLStatement.java:169)
         at com.sap.sql.jdbc.common.StatementAnalyzerImpl.check(StatementAnalyzerImpl.java:35)
         at com.sap.sql.jdbc.common.StatementAnalyzerImpl.preprepareStatement(StatementAnalyzerImpl.java:101)
         at com.sap.sql.jdbc.common.StatementAnalyzerImpl.preprepareStatement(StatementAnalyzerImpl.java:87)
         at com.sap.sql.jdbc.common.AbstractCommonStatement.parseStatement(AbstractCommonStatement.java:472)
         at com.sap.sql.jdbc.common.CommonConnectionImpl.prepareStatement(CommonConnectionImpl.java:375)
         at com.sap.engine.services.dbpool.cci.ConnectionHandle.prepareStatement(ConnectionHandle.java:81)
         at net.tnb.model.ReasonCodeEntityBean3_0Persistent.ejb_iInsert(ReasonCodeEntityBean3_0Persistent.java:306)
         at com.sap.engine.services.ejb.entity.pm.UpdatablePersistent.ejbFlush(UpdatablePersistent.java:92)
         at com.sap.engine.services.ejb.entity.pm.TransactionContext.flushAll(TransactionContext.java:429)
         at com.sap.engine.services.ejb.entity.pm.TransactionContext.flush(TransactionContext.java:378)
         at com.sap.engine.services.ejb.entity.pm.TransactionContext.beforeCompletion(TransactionContext.java:506)
         at com.sap.engine.services.ejb.entity.SynchronizationList.beforeCompletion(SynchronizationList.java:136)
         at com.sap.engine.services.ts.jta.impl.TransactionImpl.commit(TransactionImpl.java:226)
         ... 16 more

    Hi Stefan and Everyone,
    I have solved my problem. Just want to let everyone know if u have to install the SP's for WEB AS 6.30/6.40.
    You start from the installation from CD 6.30/6.40. Everything will be working at this point. You can login to Visual Admin, Config tool and SDM.
    Before you apply any SP's, do the following:
    a) Create an emergency user with the Administrator rights: Ref OSS Note:669848
    Try to follow this route for SP's:
    From CD 6.30/6.40 -> SP04 -> SP07
    Apply SP04 first before applying SP07 (Recommended Approach).
    Refer the installation guide: SAP Web AS Support Package Guide 630SP2 to 640SP4.
    Use JDK1.4.2_05 to install SP04. You must reference the following OSS Notes and apply to your system accordingly, this is the key to an error free installation:
    a) OSS Note: 697535
    b) OSS Note: 709140
    c) OSS Note: 716604
    d) OSS Note: 706378
    You have to be really careful with SP04 installation, because it changes the version from 6.30 -> 6.40.
    Once you are able to install SP04 without any problems, you can directly apply SP07 or the highest 6.40 SP.
    Kind Regards,
    Buddha.

  • How to have the JTA transaction in ServiceEndpoint interface java method

    Hi,
    I have query how to have the JTA transaction in SEI(Service endpoint interface) generated by WSDL.
    I have a MDMListener (using MDM API) which looks for a recordchange in MDM repository which needs to be send to PI7.1 via soap request.
    1) I had imported the WSDL from ESR(PI) and generated outside-in proxy.
    2) Created ejb3.0 stateless session bean using NWDS
    3) Created web service client application by generating the WSDL again (by Generate client)
    4)Added a method callPI()with Service and i set the context with endpointaddress property as the soap location of the sender agreement configured in PI7.1.
    The damean thread listener(EventDispatcher) looks for MDM record change and it calls the method callPI() from ejbsession bean by lookup to transfer the record to PI7.1 system via webservices(web method). I hit the below error.
    Exception com.sap.engine.services.ts.exceptions.BaseIllegalStateException: Status of ( SAP J2EE Engine JTA Transaction : 06223ffffffa20048fffffffe ) should be active, but it is STATUS_COMMITTED = 3.
    at com.sap.engine.services.ts.jta.impl.TransactionImpl.registerSynchronizationWithoutStatusChecks(TransactionImpl.java:672)
    at com.sap.engine.services.ts.jta.impl.TransactionImpl.registerSynchronization(TransactionImpl.java:641)
    at com.sap.engine.services.ts.transaction.TxLevelSynchronizations.addSynchronization(TxLevelSynchronizations.java:118)
    at com.sap.engine.services.ts.transaction.TxManagerImpl.registerSynchronization(TxManagerImpl.java:829)
    at com.sap.transaction.TxManager.registerSynchronization(TxManager.java:303)
    at com.sap.engine.messaging.runtime.j2ee.sapengine.SAPTransactionManager.registerSynchronization(SAPTransactionManager.java:126)
    at com.sap.engine.messaging.impl.util.tx.TxController.<init>(TxController.java:83)
    //Method in the ejb stateless session bean
    @WebServiceRef (name="DistributeMasterDataService") DistributeMasterDataService service;
    @RelMessagingNW05DTOperation(enableWSRM=true)
    public void callPi(DistributeMasterDataRequestType req) {
    port.distributeMasterDataOutA(req);// the distributeMasterDataOutA is the method available in SEI..Here is the issue on JTA
    For the first time the message(req object)transmits to the PI successfully,but for the second call i hit this JTA Transaction :status should be active, but it is STATUS_COMMITTED = 3.
    I tried chanding the transactionmanagement from container to bean.
    @TransactionManagement(value=TransactionManagementType.BEAN)
    @TransactionAttribute(value=TransactionAttributeType.REQUIRES_NEW)
    I wanted to know how can i have the JTA transaction status in SEI(service enpoint interface)java method distributeMasterDataOutA.Since it is an interface i dont know what annotation can be used.
    If its possible i can try this UserTransaction,
    http://help.sap.com/saphelp_nw04/helpdata/de/f6/7a8df922db4ab79342b46c48dac7d0/content.htm
    ut.begin() & ut.commit(),so that everytime this method is called it will treat as a new transaction..
    Let me know if you need more details??,Any idea provided would be great.
    Thanks
    Sabarinathan

    Hello everybody,
    The issue resolved,we need to have the bean management transaction type and not the container.
    and the transactionattribute value as Requires New
    rgds
    Sabarinathan
    Edited by: Sabarinathan Selvaraj on May 12, 2009 2:17 PM

  • Weblogic 7 SP5 SQL Exceptions follow a JTA transaction timeout

    I have a problem in Weblogic 7 SP5 that was not happening in SP2. I'm using the
    Weblogic jDriver (weblogic.jdbc.mssqlserver4.Driver)
    I have a transaction that times out due to JTA transaction timeout, and then gets
    marked for rollback. For several minutes after the timeout, I get many SQL Exceptions
    with bogus messages like "invalid column name" when the column name is, in fact,
    correct.
    Then the weblogic log file shows "Exception during rollback of transaction" (javax.transaction.SystemException:
    Heuristic hazard). Next, the connection is tested on reserve, this test fails,
    and the connection is refreshed. As soon as the connection is refreshed, I stop
    getting SQL exceptions and everything starts working correctly again.
    It seems like the transaction timeout is making the connection go bad, and somehow
    other requests are using this bad connection before the transaction finishes rolling
    back. What could the problem be? Some excerpts from my app log and weblogic log
    are below.
    com.workpoint.server.ejb.WorkPointEJBException: The transaction is no longer active
    - status: 'Marked rollback. [Reason=weblogic.transaction.internal.TimedOutException:
    Transaction timed out after 901 seconds
    Name=[EJB com.storeperform.taskmgr.ejb.procrelease.ProcReleaseBean.distributeToOrgUnit(com.storeperform.taskmgr.values.DistributionUnit)],Xid=17109:68c10765ba68aaaa(12114044),Status=Active,numRepliesOwedMe=0,numRepliesOwedOthers=0,seconds
    since begin=901,seconds left=60,activeThread=Thread[WorkQueueThread[q=1, qName=ProcReleaseTaskWorkers,
    id=6],5,WorkQueueGroup[id=1, name=ProcReleaseTaskWorkers]],ServerResourceInfo[weblogic.jdbc.jts.Connection]=(state=ended,assigned=none,xar=weblogic.jdbc.jts.Connection@18cd616,re-Registered
    = false),SCInfo[DomainManager+edwards-s1]=(state=active),properties=({weblogic.transaction.name=[EJB
    com.storeperform.taskmgr.ejb.procrelease.ProcReleaseBean.distributeToOrgUnit(com.storeperform.taskmgr.values.DistributionUnit)],
    weblogic.jdbc=t3://10.10.3.17:7001}),OwnerTransactionManager=ServerTM[ServerCoordinatorDescriptor=(CoordinatorURL=edwards-s1+10.10.3.17:7001+DomainManager+t3+,
    Resources={})],CoordinatorURL=edwards-s1+10.10.3.17:7001+DomainManager+t3+)]'.
    No further JDBC access is allowed within this transaction.SQL Command = INSERT
    INTO WP_PROCI_NODE_HIST (NODE_HIST_ID, NODE_HIST_DB, PROCI_ID, PROCI_DB, PROCI_NODE_ID,
    PROCI_NODE_DB, NODE_ITERATION, NODE_STATE_ID, ROW_VERSION, LU_ID, LU_DATE) VALUES
    weblogic.jdbc.mssqlserver4.TdsException: Invalid column name 'user_fname'.
    [from weblogic log]
    ####<Jun 17, 2004 8:14:16 AM MDT> <Error> <EJB> <EDWARDS> <edwards-s1> <WorkQueueThread[q=1,
    qName=ProcReleaseTaskWorkers, id=7]> <kernel identity> <> <010025> <Exception
    during rollback of transaction Name=[EJB com.storeperform.taskmgr.ejb.procrelease.ProcReleaseBean.distributeToOrgUnit(com.storeperform.taskmgr.values.DistributionUnit)],Xid=17439:68c10765ba68aaaa(31878774),Status=Rolled
    back. [Reason=weblogic.transaction.internal.AppSetRollbackOnlyException],HeuristicErrorCode=XA_HEURHAZ,numRepliesOwedMe=0,numRepliesOwedOthers=0,seconds
    since begin=3,seconds left=57,ServerResourceInfo[weblogic.jdbc.jts.Connection]=(state=rolledback,assigned=edwards-s1,xar=weblogic.jdbc.jts.Connection@15e1b7e,re-Registered
    = false),SCInfo[DomainManager+edwards-s1]=(state=rolledback),properties=({weblogic.transaction.name=[EJB
    com.storeperform.taskmgr.ejb.procrelease.ProcReleaseBean.distributeToOrgUnit(com.storeperform.taskmgr.values.DistributionUnit)],
    weblogic.jdbc=t3://10.10.3.17:7001}),OwnerTransactionManager=ServerTM[ServerCoordinatorDescriptor=(CoordinatorURL=edwards-s1+10.10.3.17:7001+DomainManager+t3+,
    Resources={})],CoordinatorURL=edwards-s1+10.10.3.17:7001+DomainManager+t3+): javax.transaction.SystemException:
    Heuristic hazard: (weblogic.jdbc.jts.Connection, HeuristicHazard, (javax.transaction.xa.XAException:
    I/O exception while talking to the server, java.io.EOFException))
    ####<Jun 17, 2004 8:14:17 AM MDT> <Warning> <JDBC> <EDWARDS> <edwards-s1> <ExecuteThread:
    '8' for queue: 'default'> <kernel identity> <> <001094> <A connection from pool
    "sp_connection_pool" was tested during reserve with the SQL "select 1" and failed:
    weblogic.jdbc.mssqlserver4.TdsException: I/O exception while talking to the server,
    java.io.EOFException
    ...[stack trace omitted]...
    This connection will now be refreshed.>

    Brad Swanson wrote:
    According to BEA's documentation, the jDriver is deprecated (no longer supported)
    in WLS 7 SP5. Not sure when they stopped supporting it, but sometime after SP2,
    apparently. Our solution, unfortunately, was to stay with SP2. Using the newer,
    supported JDBC driver would presumably fix the problem, but we didn't have time
    to do a full regression test with a different driver.Hi, no. The jDriver is deprecated, not unsupported. For WLS releases that contain
    the jDriver it will be supported for as long as we support the WLS release!
    Deprecation just means that we may choose to not supply that driver in any future
    release, and will not support it in that or any subsequent release.
    Practically, much depends on which jDriver you're using. In decreasing order
    of practical support we have: The weblogic.jdbc.oci.Driver to Oracle: We do actively
    continue to fix bugs in it. The weblogic.jdbc.mssqlserver4.Driver: Very unlikely that
    we will fix any new problem with it. The weblogic.jdbc.ifmx.Driver: Even less
    likely that we will do anything with it...
    I hope that makes it better for you.
    Joe

  • JTA Transaction--please help-----Xid not valid

    HI,
    I am writing a small application which i am posting at the end.This is decription of my application.I am writing a jsp.Later on i will be using in some other way.
    I am using Oracle XA implementation to communicatewith my RM which oracle8.1.7 .
    I am creating two XAConnection with two data instances 'test' and 'test3' .These two reside on my local machine in the same database server.
    With the code which i am sending you i have tried two cases.
    First Case
    1)i use only one XAConnection object of say 'test'.
    2)enlist its XADataSource with my transaction Object
    3) get two connection objects and execute two sql's on themMy code works fine and maintains the transaction.
    Second Case
    1) I use create two XAConnection objects. one of 'test' and other of 'test3'.
    2) enlist their XAResources with transaction object.
    3) Now i take one connection from each of XAConnection and execute two sqls, oneon each of them.
    It gives me exception while enlisting second XAResource with transaction objeectsaying that "The Xid is not valid".
    below is the stackTrace.
    javax.transaction.SystemException: start() failed on resource 'oracle.jdbc.xa.client.OracleXAResource':XAER_NOTA : The XID is not valid
    oracle.jdbc.xa.OracleXAException at oracle.jdbc.xa.OracleXAResource.checkError(OracleXAResource.java:483)
    at oracle.jdbc.xa.client.OracleXAResource.start(OracleXAResource.java:190)
    at weblogic.transaction.internal.ServerResourceInfo.start(ServerResourceInfo.java:1165)
    at weblogic.transaction.internal.ServerResourceInfo.xaStart(ServerResourceInfo.java:1108)
    <----------------------CODE------------------------------------------------------>
    <html>
    <body bgcolor=tan>
    <%@page session="true" %>
    <%@page import="java.util.Hashtable,java.sql.*,javax.naming.*,javax.transaction.*,javax.sql.*,oracle.jdbc.xa.client.OracleXADataSource,javax.rmi.PortableRemoteObject,javax.transaction.xa.XAResource" %>
    <%!
    private static XAConnection getFirstXAConnection() throws java.sql.SQLException{
         OracleXADataSource oxadsFirst = new OracleXADataSource();
         String urlFirst = "jdbc:oracle:thin:@70.7.51.80:1521:test";
         oxadsFirst.setURL(urlFirst);
         XAConnection xaConnectionFirst = oxadsFirst.getXAConnection("scott","tiger");
    return xaConnectionFirst;
    private static XAConnection getSecondXAConnection() throws java.sql.SQLException{
              OracleXADataSource oxadsSec= new OracleXADataSource();
              String urlSec = "jdbc:oracle:thin:@70.7.51.80:1521:test3";
              oxadsSec.setURL(urlSec);
              XAConnection xaConnectionSec = oxadsSec.getXAConnection("scott","tiger");
    return xaConnectionSec;
    %>
    <%
    Context ctx = null;
         Hashtable ht = new Hashtable();
         ht.put(Context.INITIAL_CONTEXT_FACTORY, "weblogic.jndi.WLInitialContextFactory");
         ht.put(Context.PROVIDER_URL, "t3://localhost:7001");
         try{
              ctx = new InitialContext(ht);
              //javax.transaction.UserTransaction transaction = (javax.transaction.UserTransaction)ctx.lookup("java:comp/UserTransaction");
              System.out.println("Before Lookup JNDI UserTransaction and TransactionManager......................");
              //javax.transaction.UserTransaction userTx = (javax.transaction.UserTransaction)ctx.lookup("javax.transaction.UserTransaction");
              javax.transaction.TransactionManager transactionManager = (javax.transaction.TransactionManager)ctx.lookup("javax.transaction.TransactionManager");
              System.out.println("After Lookup TransactionManager......................");
    try{
                   transactionManager.begin();
                   Transaction transaction = transactionManager.getTransaction();
                   System.out.println("Transaction Object ----------------------------->"+transaction);
    XAConnection xaConFirst = getFirstXAConnection();
    XAResource xaResourceFirst = xaConFirst.getXAResource();
    System.out.println("xaResourceFirst Object ----------------------------->"+xaResourceFirst);
    XAConnection xaConSecond = getSecondXAConnection();
    XAResource xaResourceSecond = xaConSecond.getXAResource();
    System.out.println("xaResourceSecond Object ----------------------------->"+xaResourceSecond);
    if(!xaResourceFirst.isSameRM(xaResourceSecond) )
    System.out.println("<-----------------BOTH THE RESOURCES ARE NOT SAME SMAE SAME----------------------------->");
    boolean firstEnlistBool = transaction.enlistResource(xaResourceFirst);
    System.out.println("firstEnlistBool ----------------------------->"+firstEnlistBool);
    boolean secondEnlistBool = transaction.enlistResource(xaResourceSecond);
    System.out.println("secondEnlistBool -------------------------> "+secondEnlistBool);
    java.sql.Connection firstConn = xaConFirst.getConnection();
    Statement stmt = firstConn.createStatement();
    stmt.executeQuery("insert into dept values(60,'MARKETING','NEW DELHI')");
    java.sql.Connection secondConn = xaConSecond.getConnection();//xaConFirst.getConnection();//
    stmt = secondConn.createStatement();
    //stmt.executeQuery("insert into account values(20,20)");
    stmt.executeQuery("insert into salgrade values(10,10,10)");
    if(Status.STATUS_ACTIVE == transactionManager.getStatus() )
    System.out.println("Before committing status "+transactionManager.getStatus() );
    transactionManager.commit();
    System.out.println("After committing");
              } catch(SQLException sqlE){
                        sqlE.printStackTrace();
                        catch(Exception e){
                                            e.printStackTrace();
         } catch (Exception ex) {
              ex.printStackTrace();
              finally {
                   try {
                        ctx.close();
                        catch (Exception e) {
                             e.printStackTrace();
                   } // close finally
    %>
    <form method="post">
    <input type="submit" name="submit" value="Call Transaction Bean">
    </form>
    </html>
    <-------------------------------------------------------------------------------->
    please help in this..I am stuck with this and dont kow how to move ahead to remove this problem..
    Best Regards
    Akhil Nagpal

    Hi,
    Hi Vicky,
    I think we are in different time zones. I am south
    korea.I have tried your suggestion but it gives me
    the same exception.Yes ,there is a difference of 3.5 hours , I am in India(Mumbai).
    This is what i am trying to achieve.
    My aim is to create some aplication to which i can
    register my XADataSources and this application should
    be able to handle the distributed transactions among
    them.I will be using the TransactionManager of some
    application server.SO i am using weblogic7.0.
    For the testing purpose i have creaed a jsp as i
    i posted the code. I am very new to this JTA and may
    be i am doing wrong.Can you help me this but putting
    insights into your experience may be that will
    increase my enthusiasm :-) ....
    please help me in this.
    I am extracting the following from the docs
    public interface TransactionManager
    The TransactionManager interface defines the methods that allow an application server to manage transaction boundaries.
    public interface UserTransaction
    The UserTransaction interface defines the methods that allow an application to explicitly manage transaction boundaries
    So as per your specs I can understands your application is trying to explicitily control the boundaries of the transaction, so you should use the UserTransction instance to begin the Transaction.My understanding says the TransactionManager will come in picture for declarative transaction and UserTransaction for the your case.I think you have tried that , I would have tried this out here but I dont work on weblogic.Do the things cooly and try to understand the concept.Let me know of the results.
    Regards
    Vicky

  • JTA transaction is aborting due to an user rollback fault

    Hi,
    While testing the ReceiptEBS on EM, we are getting given error, few minutes before EBS was working fine.
    Error -
    The selected operation CreateReceiptList could not be invoked.
    An exception occured while invoking the webservice operation. Please see logs for more details.
    oracle.sysman.emSDK.webservices.wsdlapi.SoapTestException: Global retry rollback fault thrown.
    The current JTA transaction is aborting due to an user rollback fault being thrown. The upstream component should retry in a new
    JTA transaction upon catching this fault.
    This exception was caused by a global retry fault being thrown from downstream component. The user had directed the BPEL engine to roll
    back the current JTA transaction and retry within new JTA transactions for the specified number of times and retry interval.
    There is no action recommended.
    oracle.sysman.emSDK.webservices.wsdlapi.SoapTestException: Global retry rollback fault thrown.
    The current JTA transaction is aborting due to an user rollback fault being thrown. The upstream component should retry in a
    new JTA transaction upon catching this fault.
    This exception was caused by a global retry fault being thrown from downstream component. The user had directed the BPEL engine
    to roll back the current JTA transaction and retry within new JTA transactions for the specified number of times and retry interval.
    There is no action recommended.

    Hi,
    This seems to be a timeout error during JTA transaction. Some of my suggestions are
    1. Put a timeout value in the partner link properties.
    2. Set the timeout parameter for JTA under Domain configuration in console.
    Regards,
    Rahul

  • JTA Transaction does not work

    Hi,
    I am currently porting an application from Websphere 3.5 to Weblogic 6.1.
    I have an Oracle 8.1.7 database.
    I have a problem when rollbacking JTA transaction.
    I have a session bean manipulating Entity beans (CMP & BMP) within a single
    method.
    This method creates beans and then update them.
    The issue is that during the update, the application generates an exception
    (system or applicative). The method rollbacks the transaction, but if I look
    in the database, the insert requests are not rollbacked !
    I have tried two different approach:
    1) container manage transaction: I catch the exception and then call
    setRollbackOnly()
    2) bean manage transaction: I retrieve the user transaction, and apply the
    rollback on exception.
    What's wrong with that ? This actually works fine on Websphere.
    Regards
    Jacques Desmazieres

    Make sure that you are using a TxDataSource and not a plain DataSource.
    (This is configured in the console.)
    -- Rob
    Jacques Desmazieres wrote:
    Hi,
    I am currently porting an application from Websphere 3.5 to Weblogic 6.1.
    I have an Oracle 8.1.7 database.
    I have a problem when rollbacking JTA transaction.
    I have a session bean manipulating Entity beans (CMP & BMP) within a single
    method.
    This method creates beans and then update them.
    The issue is that during the update, the application generates an exception
    (system or applicative). The method rollbacks the transaction, but if I look
    in the database, the insert requests are not rollbacked !
    I have tried two different approach:
    1) container manage transaction: I catch the exception and then call
    setRollbackOnly()
    2) bean manage transaction: I retrieve the user transaction, and apply the
    rollback on exception.
    What's wrong with that ? This actually works fine on Websphere.
    Regards
    Jacques Desmazieres

  • EJB3 : suspend JTA transaction does not release the connection in the XA DS

    Hi all,
    I did a test and after suspending a JTA transaction I note that in the xa datasource the activeconnection = 1.
    So is it normal because I was thinking that when I suspend the transaction the teh connection is released and then after a transaction resume I could continue the transaction with another connection of the xa datasource ?
    Thank you for all..
    Christophe.

    It's a long time ago, but did you ever solve this problem?
    I'm having the same issue with OSB writing to a WLS8.1 JMS queue.
    I have a development OSB server which works fine.
    Pete

Maybe you are looking for

  • How do I install the new upgrade when the system will not let me? Help!!! I have tried to do this 30 times or MORE!

    I tried to add upgrade but when I put the icon into my Applications there appears a white x on the icon after I have downloaded the upgrade. Sometimes a statement like; You do not have permission to use upgrade? (error message)

  • Request Message Mapping Problem

    Hello friends, I am working in XI 2.0 and my senario is sap R/3->XI->File Adapter I take an idoc from the SAP R/3 system. and that comes properly to XI. I already created Data type, Message Type, Interface Type, Message Mapping and Interface Mapping

  • External sounds quit working

    I have reseached this and find that many have asked questions about sounds on their Ipod touch.  My 8G external sound has quitl.  I just downloaded the latest update and now I have no sound when I type, unlock or play games.  I do have sound using he

  • Temporary email address in Transaction ME21N

    Experts I want to maintain (temporary email address in Transaction ME21N) e-mail address in the PO header details of the vendor and the system has to send the PO from the temporary email address. But it is considering from the vendor master only .How

  • Reports, HTML vs CSV formatting...

    Hi, I have a report that in its response has one field which includes many values, like "roles"... when the report is visible in the browser, it looks good when one adds a br-tag between the different roles, but this is not a good "look" for it when