Hello,
I have a big problem with my application.
I have a transaction witch will take some time to complete - about 10 minutes in
general. Here the transaction context is Required. Inside the trancation many entity
beans are accessed, removed and created.
During this transaction someone could walk on the website - the website also needs
read-access to the same beans.
To avoid deadlocks I'm using "Instance Per Transaction CMP 2.x EntityBean" as
container-configuration.
The problem occures, that the calls to the website even are going though a
transaction-type "Never" SessionBean call and are blocked - so I will get the
following error:
Caused by: javax.ejb.EJBException: Update failed. Expected one affected row:
rowsAffected=0id=136026
at
org.jboss.ejb.plugins.cmp.jdbc.JDBCStoreEntityCommand.execute(Lorg.jboss.ejb.EntityEnterpriseContext;)V(Optimized
Method)
at
org.jboss.ejb.plugins.cmp.jdbc.JDBCStoreManager.storeEntity(Lorg.jboss.ejb.EntityEnterpriseContext;)V(Optimized
Method)
at
org.jboss.ejb.plugins.CMPPersistenceManager.storeEntity(Lorg.jboss.ejb.EntityEnterpriseContext;)V(Optimized
Method)
at
org.jboss.resource.connectionmanager.CachedConnectionInterceptor.storeEntity(Lorg.jboss.ejb.EntityEnterpriseContext;)V(Optimized
Method)
at
org.jboss.ejb.GlobalTxEntityMap.synchronizeEntities(Ljavax.transaction.Transaction;)V(Optimized
Method)
at
org.jboss.ejb.GlobalTxEntityMap$GlobalTxEntityMapSynchronize.beforeCompletion()V(Optimized
Method)
at org.jboss.tm.TransactionImpl.doBeforeCompletion()V(Optimized Method)
at org.jboss.tm.TransactionImpl.commit()V(Optimized Method)
at
org.jboss.ejb.plugins.TxInterceptorCMT.endTransaction(Lorg.jboss.invocation.Invocation;Ljavax.transaction.Transaction;Ljavax.transaction.Transaction;)V(Optimize
at
org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(Lorg.jboss.invocation.Invocation;)Ljava.lang.Object;(Optimized
Method)
at
org.jboss.ejb.plugins.TxInterceptorCMT.invoke(Lorg.jboss.invocation.Invocation;)Ljava.lang.Object;(Optimized
Method)
at
org.jboss.ejb.plugins.SecurityInterceptor.invoke(Lorg.jboss.invocation.Invocation;)Ljava.lang.Object;(Optimized
Method)
at
org.jboss.ejb.plugins.LogInterceptor.invoke(Lorg.jboss.invocation.Invocation;)Ljava.lang.Object;(Optimized
Method)
at
org.jboss.ejb.plugins.ProxyFactoryFinderInterceptor.invoke(Lorg.jboss.invocation.Invocation;)Ljava.lang.Object;(Optimized
Method)
at
org.jboss.ejb.EntityContainer.internalInvoke(Lorg.jboss.invocation.Invocation;)Ljava.lang.Object;(Optimized
Method)
at
org.jboss.ejb.Container.invoke(Lorg.jboss.invocation.Invocation;)Ljava.lang.Object;(Optimized
Method)
at
org.jboss.ejb.plugins.local.BaseLocalProxyFactory.invoke(Ljava.lang.Object;Ljava.lang.reflect.Method;[Ljava.lang.Object;)Ljava.lang.Object;(Optimized
Method)
at
org.jboss.ejb.plugins.local.EntityProxy.invoke(Ljava.lang.Object;Ljava.lang.reflect.Method;[Ljava.lang.Object;)Ljava.lang.Object;(Optimized
Method)
at $Proxy102.getModifiedDate()Ljava.util.Date;(Unknown Source)
May this be a result of a container managed relationship?
All getter of this entity beans are marked as "supported" transaction.
The last possibility would be to create special read-only entity beans for calling
them for website displaying - but this will result in a lot of work. is there maybe
another solution what I've not found?
Thank you very much,
Sascha Kulawik
View the original post :
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3830745#3830745
Reply to the post :
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3830745
-------------------------------------------------------
This SF.Net email is sponsored by: IBM Linux Tutorials
Free Linux tutorial presented by Daniel Robbins, President and CEO of
GenToo technologies. Learn everything from fundamentals to system
administration.http://ads.osdn.com/?ad_id=1470&alloc_id=3638&op=click
_______________________________________________
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user