transaction times out

marc


|-----Original Message-----
|From: [EMAIL PROTECTED]
|[mailto:[EMAIL PROTECTED]]On Behalf Of [EMAIL PROTECTED]
|Sent: Friday, November 24, 2000 3:30 AM
|To: jBoss
|Subject: [jBoss-User] entity transaction lost ? Bean not written to db !
|
|
|
|Hello !
|
|Again i have a problem with entity beans getting written
|to the database:
|
|i have a entity bean with a very long running create-method
|(up to 10 minutes). This bean is deployed with standard
|container-configuration (i think commit option A) and
|transaction-attribute required.
|When calling this bean i haven't set up a transaction, expecting
|the bean to do it on his own -
|this works as long the create method doesn't last to long !
|
|the bean with "shorter" create-method gets correctly written
|to the db. The bean with "longer" create-method vanishes,
|never to be seen again.
|
|An experiment with an explicit ejbContext.getUserTransaction().commit()
|at the end of the create method works with a short running
|variant of the create-method, but with the long-running version
|i get an :
|java.rmi.ServerException: Container exception. Notify the
|container developers :-); nested exception is:
|        java.lang.IllegalStateException: No transaction.
|
|full listing see below.
|
|My questions are:
|1. Is it generally not allowed to have
|     a long running create-method ?
|2. Is it generally not allowed to have
|     a commit at the end of a create-method ?
|3. Why does it work with a shorter create-method
|     and not with a longer one ?
|
|
|thx in advance
|
|-----
|markus
|
|
|Full StackTrace is here:
|
|java.rmi.ServerException: Container exception. Notify the
|container developers :-); nested exception is:
|        java.lang.IllegalStateException: No transaction.
|java.lang.IllegalStateException: No transaction.
|        at
|org.jboss.tm.TransactionImpl.setRollbackOnly(TransactionImpl.java:148)
|        at
|org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterc
|eptorCMT.java:270)
|        at
|org.jboss.ejb.plugins.TxInterceptorCMT.invokeHome(TxInterceptorCMT.java:86)
|        at
|org.jboss.ejb.plugins.SecurityInterceptor.invokeHome(SecurityInterc
|eptor.java:126)
|        at
|org.jboss.ejb.plugins.LogInterceptor.invokeHome(LogInterceptor.java:106)
|        at
|org.jboss.ejb.EntityContainer.invokeHome(EntityContainer.java:316)
|        at
|org.jboss.ejb.plugins.jrmp.server.JRMPContainerInvoker.invokeHome(J
|RMPContainerInvoker.java:143)
|        at
|org.jboss.ejb.plugins.jrmp.server.JRMPContainerInvoker.invokeHome(J
|RMPContainerInvoker.java:191)
|        at
|org.jboss.ejb.plugins.jrmp.interfaces.HomeProxy.invoke(HomeProxy.java:198)
|        at $Proxy35.create(Unknown Source)
|        at
|de.dig.vsa.stat.Statistikpool$StatCreateThread.run(Statistikpool.java:265)
|        at
|de.dig.dfc.ThreadPoolManager$ServiceThread.run(ThreadPoolManager.java:273)
|
|----------------------------------------------
|
|immediately precding this is the following error:
|
|Thread-38 12:03:10,735 ERROR ++ejb.statistic [ejbCreate] Failed to
|create bean in database
|javax.transaction.RollbackException: Already marked for rollback
|        at org.jboss.tm.TxCapsule.commit(TxCapsule.java:271)
|        at org.jboss.tm.TransactionImpl.commit(TransactionImpl.java:76)
|        at org.jboss.tm.TxManager.commit(TxManager.java:106)
|        at
|org.jboss.ejb.EnterpriseContext$UserTransactionImpl.commit(Enterpri
|seContext.java:295)
|        at
|de.dig.vsb.ejb.statistic.StatisticBean.ejbCreate(StatisticBean.java:158)
|        at java.lang.reflect.Method.invoke(Native Method)
|        at
|org.jboss.ejb.plugins.BMPPersistenceManager.createEntity(BMPPersist
|enceManager.java:120)
|        at
|org.jboss.ejb.EntityContainer.createHome(EntityContainer.java:441)
|        at java.lang.reflect.Method.invoke(Native Method)
|        at
|org.jboss.ejb.EntityContainer$ContainerInterceptor.invokeHome(Entit
|yContainer.java:639)
|        at
|org.jboss.ejb.plugins.EntitySynchronizationInterceptor.invokeHome(E
ntitySynchronizationInterceptor.java:160)
|        at
|org.jboss.ejb.plugins.EntityInstanceInterceptor.invokeHome(EntityIn
|stanceInterceptor.java:86)
|        at
|org.jboss.ejb.plugins.TxInterceptorCMT.invokeNext(TxInterceptorCMT.
|java:135)
|        at
|org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterc
|eptorCMT.java:263)
|        at
|org.jboss.ejb.plugins.TxInterceptorCMT.invokeHome(TxInterceptorCMT.java:86)
|        at
|org.jboss.ejb.plugins.SecurityInterceptor.invokeHome(SecurityInterc
|eptor.java:126)
|        at
|org.jboss.ejb.plugins.LogInterceptor.invokeHome(LogInterceptor.java:106)
|        at
|org.jboss.ejb.EntityContainer.invokeHome(EntityContainer.java:316)
|        at
|org.jboss.ejb.plugins.jrmp.server.JRMPContainerInvoker.invokeHome(J
|RMPContainerInvoker.java:143)
|        at
|org.jboss.ejb.plugins.jrmp.server.JRMPContainerInvoker.invokeHome(J
|RMPContainerInvoker.java:191)
|        at
|org.jboss.ejb.plugins.jrmp.interfaces.HomeProxy.invoke(HomeProxy.java:198)
|        at $Proxy35.create(Unknown Source)
|        at
|de.dig.vsa.stat.Statistikpool$StatCreateThread.run(Statistikpool.java:265)
|        at
|de.dig.dfc.ThreadPoolManager$ServiceThread.run(ThreadPoolManager.java:273)
|
|--
|gruss
|markus
|
|
|
|--
|--------------------------------------------------------------
|To subscribe:        [EMAIL PROTECTED]
|To unsubscribe:      [EMAIL PROTECTED]
|Problems?:           [EMAIL PROTECTED]
|
|



--
--------------------------------------------------------------
To subscribe:        [EMAIL PROTECTED]
To unsubscribe:      [EMAIL PROTECTED]
Problems?:           [EMAIL PROTECTED]

Reply via email to