Discussions

EJB programming & troubleshooting: RollBack and BES

  1. RollBack and BES (3 messages)

    People,

        I've a big trouble.... I've a web application where the user submits de form and some trigger from the database returns a msg ... a RemoteException is generated... but the trigger's msg doesn't appear in the screen for the user... and another msg is diplayed "org.omg.CORBA.UNKNOWN: vmcid: 0x0 minor code: 0 completed: No; nested exception is: org.omg.CORBA.UNKNOWN: vmcid: 0x0 minor code: 0 completed: No". The trigger's msg I just can see on the BES console. Anybody knows how I can get exactly the trigger's msg to display to my user?

    Tks for the help.


    Ana Paula

    Threaded Messages (3)

  2. RollBack and BES[ Go to top ]

    Hi,

    From my experience CORBA exceptions replaces the 'normal' ones when these 'normal' exceptions can not be serialized. Either the exception is not serializable or it claims to be serializable, but has a non-transient reference to non-serializable object.
    Is there a place where you can catch all Exceptions, replace it by newly created and re-throw them?
  3. Still a problem[ Go to top ]

    Victor,

       I've a class to treat some especial exceptions and this class I changed to implements Serializable... and still don't work.... I don't know if you understand my doubt...

    My struts do the setVO but the database rollback the transaction because of a rule .... example: I put a number on a field that should not have numbers (like a name of a person).... and the rule from the database returns me a msg that I would like to show and it isn't comming to my application.
  4. RollBack and BES[ Go to top ]

    see the msg that appears in the console
    and this :"ca.gcf.util.SqlEx: ERRO 0462: Erro no nome do estudante (NUMEROS). Impossivel cadastrar!!!" I would like to show to the user..



    2005-08-09 15:22:47,371 ERROR - STACK TRACE
    ca.gcf.util.SqlEx: ERRO 0462: Erro no nome do estudante (NUMEROS). Impossivel cadastrar!!!
    at ca.gcf.jdbc.DrvObj.readError(DrvObj.java:773)
    at ca.gcf.jdbc.JdbcStmt.readError(JdbcStmt.java:2259)
    at ca.gcf.jdbc.DrvObj.readResults(DrvObj.java:629)
    at ca.gcf.jdbc.JdbcStmt.readResults(JdbcStmt.java:2156)
    at ca.gcf.jdbc.JdbcStmt.readResults(JdbcStmt.java:2107)
    at ca.gcf.jdbc.JdbcPrep.exec(JdbcPrep.java:915)
    at ca.gcf.jdbc.JdbcPrep.executeUpdate(JdbcPrep.java:505)
    at com.inprise.ejb.cmp.JdbcManager.executeUpdate(JdbcManager.java:2923)
    at com.inprise.ejb.cmp.JdbcManager.store(JdbcManager.java:2413)
    at com.inprise.ejb.cmp.OneToManyManager.store(OneToManyManager.java:158)
    at com.inprise.ejb.cmp.CompoundManager.store(CompoundManager.java:578)
    at com.inprise.ejb.cmp.FieldManager.store(FieldManager.java:418)
    at com.inprise.ejb.cmp.DefaultManager.store(DefaultManager.java:134)
    at com.inprise.ejb.cmp.StoreMethod.invoke(StoreMethod.java:23)
    at com.inprise.ejb.EJBContext.invoke(EJBContext.java:166)
    at com.inprise.ejb.Dispatcher.doInvoke(Dispatcher.java:1354)
    at com.inprise.ejb.Dispatcher.invokeSecurityCheck(Dispatcher.java:1062)
    at com.inprise.ejb.Dispatcher.invoke(Dispatcher.java:824)
    at com.inprise.ejb.Dispatcher.store(Dispatcher.java:758)
    at com.inprise.ejb.EntityTable$BeforeCompletionCallback.invoke(EntityTable.java:903)
    at com.inprise.ejb.SynchronizationPool$Synchronization.doCallback(SynchronizationPool.java:213)
    at com.inprise.ejb.SynchronizationPool$Synchronization.before_completion(SynchronizationPool.java:242)
    at org.omg.CosTransactions._SynchronizationStub.before_completion(_SynchronizationStub.java:27)
    at com.inprise.ejb.jts.Transaction.commit(Transaction.java:421)
    at org.omg.CosTransactions._TerminatorStub.commit(_TerminatorStub.java:27)
    at com.inprise.ejb.jts.gen._TxStub.commit(_TxStub.java:46)
    at com.visigenic.services.CosTransactions.CurrentImpl.commit(CurrentImpl.java:254)
    at com.visigenic.services.CosTransactions.TSCurrentManager.commit(TSCurrentManager.java:87)
    at com.inprise.visitransact.jta.TransactionManagerImpl.commit(TransactionManagerImpl.java:198)
    at com.inprise.ejb.Dispatcher.endGlobalTransaction(Dispatcher.java:267)
    at com.inprise.ejb.Dispatcher.doInvoke(Dispatcher.java:1611)
    at com.inprise.ejb.Dispatcher.invokeSecurityCheck(Dispatcher.java:1062)
    at com.inprise.ejb.Dispatcher.invoke(Dispatcher.java:824)
    at com.inprise.ejb.Dispatcher.invoke(Dispatcher.java:603)
    at com.inprise.ejb.EJBHome.dispatcherInvokeBeanMethod(EJBHome.java:60)
    at com.inprise.ejb.EJBHome$ComponentInterfaceMethodCache.invokeDispatcherMethod(EJBHome.java:1552)
    at com.inprise.ejb.EJBHome.invokeDispatcherMethod(EJBHome.java:38)
    at com.inprise.ejb.Dispatcher.invoke(Dispatcher.java:429)
    at org.cieers.servicebroker.ServiceBrokerRemotePOAInvokeHandler.setVO(ServiceBrokerRemotePOAInvokeHandler.java:57)
    at org.cieers.servicebroker.ServiceBrokerRemotePOAInvokeHandler.setVO(ServiceBrokerRemotePOAInvokeHandler.java:155)
    at org.cieers.servicebroker.ServiceBrokerRemotePOA._invoke(ServiceBrokerRemotePOA.java:84)
    at org.cieers.servicebroker.ServiceBrokerRemotePOA._invoke(ServiceBrokerRemotePOA.java:47)
    at com.inprise.vbroker.poa.POAImpl.invoke(POAImpl.java:2888)
    at com.inprise.vbroker.poa.ActivationRecord.invoke(ActivationRecord.java:187)
    at com.inprise.vbroker.poa.ServerInterceptorManager$ARWrapper.invoke(ServerInterceptorManager.java:115)
    at com.inprise.vbroker.GIOP.GiopProtocolAdapter.doRequest(GiopProtocolAdapter.java:862)
    at com.inprise.vbroker.IIOP.ServerProtocolAdapter.doRequest(ServerProtocolAdapter.java:68)
    at com.inprise.vbroker.GIOP.GiopProtocolAdapter.dispatchMessage(GiopProtocolAdapter.java:1152)
    at com.inprise.vbroker.orb.TPDispatcherImpl$TPDispatcher.run(TPDispatcherImpl.java:108)
    at com.inprise.vbroker.orb.ThreadPool$PoolWorker.run(ThreadPool.java:83)
    2005-08-09 15:22:47,418 ERROR - Throwing TransactionRolledbackException for the method: public abstract void javax.ejb.EntityBean.ejbStore() throws javax.ejb.EJBException,java.rmi.RemoteException
    java.rmi.RemoteException: Failed to execute tuned store "UPDATE "estudante" SET "nm_estudante" = ? WHERE "cd_estudante" = ?" args: [ANA PAULA VIEIRA1, 544345]; nested exception is:
    ca.gcf.util.SqlEx: ERRO 0462: Erro no nome do estudante (NUMEROS). Impossivel cadastrar!!!
    at com.inprise.ejb.cmp.JdbcManager.storeException(JdbcManager.java:2509)
    at com.inprise.ejb.cmp.JdbcManager.store(JdbcManager.java:2481)
    at com.inprise.ejb.cmp.OneToManyManager.store(OneToManyManager.java:158)
    at com.inprise.ejb.cmp.CompoundManager.store(CompoundManager.java:578)
    at com.inprise.ejb.cmp.FieldManager.store(FieldManager.java:418)
    at com.inprise.ejb.cmp.DefaultManager.store(DefaultManager.java:134)
    at com.inprise.ejb.cmp.StoreMethod.invoke(StoreMethod.java:23)
    at com.inprise.ejb.EJBContext.invoke(EJBContext.java:166)
    at com.inprise.ejb.Dispatcher.doInvoke(Dispatcher.java:1354)
    at com.inprise.ejb.Dispatcher.invokeSecurityCheck(Dispatcher.java:1062)
    at com.inprise.ejb.Dispatcher.invoke(Dispatcher.java:824)
    at com.inprise.ejb.Dispatcher.store(Dispatcher.java:758)
    at com.inprise.ejb.EntityTable$BeforeCompletionCallback.invoke(EntityTable.java:903)
    at com.inprise.ejb.SynchronizationPool$Synchronization.doCallback(SynchronizationPool.java:213)
    at com.inprise.ejb.SynchronizationPool$Synchronization.before_completion(SynchronizationPool.java:242)
    at org.omg.CosTransactions._SynchronizationStub.before_completion(_SynchronizationStub.java:27)
    at com.inprise.ejb.jts.Transaction.commit(Transaction.java:421)
    at org.omg.CosTransactions._TerminatorStub.commit(_TerminatorStub.java:27)
    at com.inprise.ejb.jts.gen._TxStub.commit(_TxStub.java:46)
    at com.visigenic.services.CosTransactions.CurrentImpl.commit(CurrentImpl.java:254)
    at com.visigenic.services.CosTransactions.TSCurrentManager.commit(TSCurrentManager.java:87)
    at com.inprise.visitransact.jta.TransactionManagerImpl.commit(TransactionManagerImpl.java:198)
    at com.inprise.ejb.Dispatcher.endGlobalTransaction(Dispatcher.java:267)
    at com.inprise.ejb.Dispatcher.doInvoke(Dispatcher.java:1611)
    at com.inprise.ejb.Dispatcher.invokeSecurityCheck(Dispatcher.java:1062)
    at com.inprise.ejb.Dispatcher.invoke(Dispatcher.java:824)
    at com.inprise.ejb.Dispatcher.invoke(Dispatcher.java:603)
    at com.inprise.ejb.EJBHome.dispatcherInvokeBeanMethod(EJBHome.java:60)
    at com.inprise.ejb.EJBHome$ComponentInterfaceMethodCache.invokeDispatcherMethod(EJBHome.java:1552)
    at com.inprise.ejb.EJBHome.invokeDispatcherMethod(EJBHome.java:38)
    at com.inprise.ejb.Dispatcher.invoke(Dispatcher.java:429)
    at org.cieers.servicebroker.ServiceBrokerRemotePOAInvokeHandler.setVO(ServiceBrokerRemotePOAInvokeHandler.java:57)
    at org.cieers.servicebroker.ServiceBrokerRemotePOAInvokeHandler.setVO(ServiceBrokerRemotePOAInvokeHandler.java:155)
    at org.cieers.servicebroker.ServiceBrokerRemotePOA._invoke(ServiceBrokerRemotePOA.java:84)
    at org.cieers.servicebroker.ServiceBrokerRemotePOA._invoke(ServiceBrokerRemotePOA.java:47)
    at com.inprise.vbroker.poa.POAImpl.invoke(POAImpl.java:2888)
    at com.inprise.vbroker.poa.ActivationRecord.invoke(ActivationRecord.java:187)
    at com.inprise.vbroker.poa.ServerInterceptorManager$ARWrapper.invoke(ServerInterceptorManager.java:115)
    at com.inprise.vbroker.GIOP.GiopProtocolAdapter.doRequest(GiopProtocolAdapter.java:862)
    at com.inprise.vbroker.IIOP.ServerProtocolAdapter.doRequest(ServerProtocolAdapter.java:68)
    at com.inprise.vbroker.GIOP.GiopProtocolAdapter.dispatchMessage(GiopProtocolAdapter.java:1152)
    at com.inprise.vbroker.orb.TPDispatcherImpl$TPDispatcher.run(TPDispatcherImpl.java:108)
    at com.inprise.vbroker.orb.ThreadPool$PoolWorker.run(ThreadPool.java:83)
    Caused by: ca.gcf.util.SqlEx: ERRO 0462: Erro no nome do estudante (NUMEROS). Impossivel cadastrar!!!
    at ca.gcf.jdbc.DrvObj.readError(DrvObj.java:773)
    at ca.gcf.jdbc.JdbcStmt.readError(JdbcStmt.java:2259)
    at ca.gcf.jdbc.DrvObj.readResults(DrvObj.java:629)
    at ca.gcf.jdbc.JdbcStmt.readResults(JdbcStmt.java:2156)
    at ca.gcf.jdbc.JdbcStmt.readResults(JdbcStmt.java:2107)
    at ca.gcf.jdbc.JdbcPrep.exec(JdbcPrep.java:915)
    at ca.gcf.jdbc.JdbcPrep.executeUpdate(JdbcPrep.java:505)
    at com.inprise.ejb.cmp.JdbcManager.executeUpdate(JdbcManager.java:2923)
    at com.inprise.ejb.cmp.JdbcManager.store(JdbcManager.java:2413)
    ... 41 more
    2005-08-09 15:22:47,449 ERROR - Failure in synchronization callback
    javax.transaction.TransactionRolledbackException: java.rmi.RemoteException: Failed to execute tuned store "UPDATE "estudante" SET "nm_estudante" = ? WHERE "cd_estudante" = ?" args: [ANA PAULA VIEIRA1, 544345]; nested exception is:
    ca.gcf.util.SqlEx: ERRO 0462: Erro no nome do estudante (NUMEROS). Impossivel cadastrar!!!; nested exception is:
    java.rmi.RemoteException: Failed to execute tuned store "UPDATE "estudante" SET "nm_estudante" = ? WHERE "cd_estudante" = ?" args: [ANA PAULA VIEIRA1, 544345]; nested exception is:
    ca.gcf.util.SqlEx: ERRO 0462: Erro no nome do estudante (NUMEROS). Impossivel cadastrar!!!
    at com.inprise.ejb.EJBHome$RemoteStrategyImpl.getTransactionRolledbackException(EJBHome.java:815)
    at com.inprise.ejb.Dispatcher.doInvoke(Dispatcher.java:1462)
    at com.inprise.ejb.Dispatcher.invokeSecurityCheck(Dispatcher.java:1062)
    at com.inprise.ejb.Dispatcher.invoke(Dispatcher.java:824)
    at com.inprise.ejb.Dispatcher.store(Dispatcher.java:758)
    at com.inprise.ejb.EntityTable$BeforeCompletionCallback.invoke(EntityTable.java:903)
    at com.inprise.ejb.SynchronizationPool$Synchronization.doCallback(SynchronizationPool.java:213)
    at com.inprise.ejb.SynchronizationPool$Synchronization.before_completion(SynchronizationPool.java:242)
    at org.omg.CosTransactions._SynchronizationStub.before_completion(_SynchronizationStub.java:27)
    at com.inprise.ejb.jts.Transaction.commit(Transaction.java:421)
    at org.omg.CosTransactions._TerminatorStub.commit(_TerminatorStub.java:27)
    at com.inprise.ejb.jts.gen._TxStub.commit(_TxStub.java:46)
    at com.visigenic.services.CosTransactions.CurrentImpl.commit(CurrentImpl.java:254)
    at com.visigenic.services.CosTransactions.TSCurrentManager.commit(TSCurrentManager.java:87)
    at com.inprise.visitransact.jta.TransactionManagerImpl.commit(TransactionManagerImpl.java:198)
    at com.inprise.ejb.Dispatcher.endGlobalTransaction(Dispatcher.java:267)
    at com.inprise.ejb.Dispatcher.doInvoke(Dispatcher.java:1611)
    at com.inprise.ejb.Dispatcher.invokeSecurityCheck(Dispatcher.java:1062)
    at com.inprise.ejb.Dispatcher.invoke(Dispatcher.java:824)
    at com.inprise.ejb.Dispatcher.invoke(Dispatcher.java:603)
    at com.inprise.ejb.EJBHome.dispatcherInvokeBeanMethod(EJBHome.java:60)
    at com.inprise.ejb.EJBHome$ComponentInterfaceMethodCache.invokeDispatcherMethod(EJBHome.java:1552)
    at com.inprise.ejb.EJBHome.invokeDispatcherMethod(EJBHome.java:38)
    at com.inprise.ejb.Dispatcher.invoke(Dispatcher.java:429)
    at org.cieers.servicebroker.ServiceBrokerRemotePOAInvokeHandler.setVO(ServiceBrokerRemotePOAInvokeHandler.java:57)
    at org.cieers.servicebroker.ServiceBrokerRemotePOAInvokeHandler.setVO(ServiceBrokerRemotePOAInvokeHandler.java:155)
    at org.cieers.servicebroker.ServiceBrokerRemotePOA._invoke(ServiceBrokerRemotePOA.java:84)
    at org.cieers.servicebroker.ServiceBrokerRemotePOA._invoke(ServiceBrokerRemotePOA.java:47)
    at com.inprise.vbroker.poa.POAImpl.invoke(POAImpl.java:2888)
    at com.inprise.vbroker.poa.ActivationRecord.invoke(ActivationRecord.java:187)
    at com.inprise.vbroker.poa.ServerInterceptorManager$ARWrapper.invoke(ServerInterceptorManager.java:115)
    at com.inprise.vbroker.GIOP.GiopProtocolAdapter.doRequest(GiopProtocolAdapter.java:862)
    at com.inprise.vbroker.IIOP.ServerProtocolAdapter.doRequest(ServerProtocolAdapter.java:68)
    at com.inprise.vbroker.GIOP.GiopProtocolAdapter.dispatchMessage(GiopProtocolAdapter.java:1152)
    at com.inprise.vbroker.orb.TPDispatcherImpl$TPDispatcher.run(TPDispatcherImpl.java:108)
    at com.inprise.vbroker.orb.ThreadPool$PoolWorker.run(ThreadPool.java:83)
    Caused by: java.rmi.RemoteException: Failed to execute tuned store "UPDATE "estudante" SET "nm_estudante" = ? WHERE "cd_estudante" = ?" args: [ANA PAULA VIEIRA1, 544345]; nested exception is:
    ca.gcf.util.SqlEx: ERRO 0462: Erro no nome do estudante (NUMEROS). Impossivel cadastrar!!!
    at com.inprise.ejb.cmp.JdbcManager.storeException(JdbcManager.java:2509)
    at com.inprise.ejb.cmp.JdbcManager.store(JdbcManager.java:2481)
    at com.inprise.ejb.cmp.OneToManyManager.store(OneToManyManager.java:158)
    at com.inprise.ejb.cmp.CompoundManager.store(CompoundManager.java:578)
    at com.inprise.ejb.cmp.FieldManager.store(FieldManager.java:418)
    at com.inprise.ejb.cmp.DefaultManager.store(DefaultManager.java:134)
    at com.inprise.ejb.cmp.StoreMethod.invoke(StoreMethod.java:23)
    at com.inprise.ejb.EJBContext.invoke(EJBContext.java:166)
    at com.inprise.ejb.Dispatcher.doInvoke(Dispatcher.java:1354)
    ... 34 more
    Caused by: ca.gcf.util.SqlEx: ERRO 0462: Erro no nome do estudante (NUMEROS). Impossivel cadastrar!!!
    at ca.gcf.jdbc.DrvObj.readError(DrvObj.java:773)
    at ca.gcf.jdbc.JdbcStmt.readError(JdbcStmt.java:2259)
    at ca.gcf.jdbc.DrvObj.readResults(DrvObj.java:629)
    at ca.gcf.jdbc.JdbcStmt.readResults(JdbcStmt.java:2156)
    at ca.gcf.jdbc.JdbcStmt.readResults(JdbcStmt.java:2107)
    at ca.gcf.jdbc.JdbcPrep.exec(JdbcPrep.java:915)
    at ca.gcf.jdbc.JdbcPrep.executeUpdate(JdbcPrep.java:505)
    at com.inprise.ejb.cmp.JdbcManager.executeUpdate(JdbcManager.java:2923)
    at com.inprise.ejb.cmp.JdbcManager.store(JdbcManager.java:2413)
    ... 41 more
    2005-08-09 15:22:47,481 ERROR - Sub-transaction started by container rolled back
    javax.transaction.RollbackException: org.omg.CORBA.TRANSACTION_ROLLEDBACK: vmcid: 0x0 minor code: 0 completed: No
    at com.inprise.visitransact.jta.TransactionManagerImpl.commit(TransactionManagerImpl.java:200)
    at com.inprise.ejb.Dispatcher.endGlobalTransaction(Dispatcher.java:267)
    at com.inprise.ejb.Dispatcher.doInvoke(Dispatcher.java:1611)
    at com.inprise.ejb.Dispatcher.invokeSecurityCheck(Dispatcher.java:1062)
    at com.inprise.ejb.Dispatcher.invoke(Dispatcher.java:824)
    at com.inprise.ejb.Dispatcher.invoke(Dispatcher.java:603)
    at com.inprise.ejb.EJBHome.dispatcherInvokeBeanMethod(EJBHome.java:60)
    at com.inprise.ejb.EJBHome$ComponentInterfaceMethodCache.invokeDispatcherMethod(EJBHome.java:1552)
    at com.inprise.ejb.EJBHome.invokeDispatcherMethod(EJBHome.java:38)
    at com.inprise.ejb.Dispatcher.invoke(Dispatcher.java:429)
    at org.cieers.servicebroker.ServiceBrokerRemotePOAInvokeHandler.setVO(ServiceBrokerRemotePOAInvokeHandler.java:57)
    at org.cieers.servicebroker.ServiceBrokerRemotePOAInvokeHandler.setVO(ServiceBrokerRemotePOAInvokeHandler.java:155)
    at org.cieers.servicebroker.ServiceBrokerRemotePOA._invoke(ServiceBrokerRemotePOA.java:84)
    at org.cieers.servicebroker.ServiceBrokerRemotePOA._invoke(ServiceBrokerRemotePOA.java:47)
    at com.inprise.vbroker.poa.POAImpl.invoke(POAImpl.java:2888)
    at com.inprise.vbroker.poa.ActivationRecord.invoke(ActivationRecord.java:187)
    at com.inprise.vbroker.poa.ServerInterceptorManager$ARWrapper.invoke(ServerInterceptorManager.java:115)
    at com.inprise.vbroker.GIOP.GiopProtocolAdapter.doRequest(GiopProtocolAdapter.java:862)
    at com.inprise.vbroker.IIOP.ServerProtocolAdapter.doRequest(ServerProtocolAdapter.java:68)
    at com.inprise.vbroker.GIOP.GiopProtocolAdapter.dispatchMessage(GiopProtocolAdapter.java:1152)
    at com.inprise.vbroker.orb.TPDispatcherImpl$TPDispatcher.run(TPDispatcherImpl.java:108)
    at com.inprise.vbroker.orb.ThreadPool$PoolWorker.run(ThreadPool.java:83)