Bugs item #796177, was opened at 2003-08-27 19:00
Message generated for change (Tracker Item Submitted) made by Item Submitter
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=376685&aid=796177&group_id=22866

Category: JBossCMP
Group: v3.2
Status: Open
Resolution: None
Priority: 5
Submitted By: Jari Juslin (zds0)
Assigned to: Nobody/Anonymous (nobody)
Summary: JBoss failes to remove lock on CMP beans w/o transaction

Initial Comment:
JBoss 3.2.1, Red Had Linux 6.2, Sun JVM 1.4.2 for Linux



I have EJB 2.0 CMP entity bean, that was accessed both

with and without transaction. When two threads

performed operations on it's fields at the same time,

it sometimes ended up throwing exception like the one

below.



The wort part is that JBoss was not able to recover

from this: subsequent calls to that bean always threw

the same exception over and over again. This

effectively put our system out of operation, since no

retry could get through and bean clients were stuck.



We now added transactions to all the beans

participating to these operations, but this is still

something that should be corrected.



AFAIK the EJB 2.0 spec strongly recommends to always

use transactions with CMP entity beans, and lets

engines not to support accessing CMP beans w/o

transaction, but if JBoss chooses to do so it should

not let user deploy beans it can't handle correctly. 





2003-08-24 03:54:38,689 WARN 

[org.jboss.tm.TransactionImpl] Transaction

TransactionImpl:XidImpl [FormatId=257,

GlobalId=www.matchem.com//540079, BranchQual=] timed

out. status=STATUS_ACTIVE

2003-08-24 03:54:38,690 WARN 

[org.jboss.tm.TransactionImpl] Lock contention,

tx=TransactionImpl:XidImpl [FormatId=257,

GlobalId=www.matchem.com//540079, BranchQual=]

2003-08-24 03:54:38,691 ERROR [org.jboss.ejb.BeanLock]

PoolThread-10Saw rolled back tx=TransactionImpl:XidImpl

[FormatId=257, GlobalId=www.matchem.com//540079,

BranchQual=] waiting for txLock

2003-08-24 03:54:38,691 ERROR [org.jboss.ejb.BeanLock]

removing bean lock and it has tx set! QPL

bean=MITVCharacter id=[.158285.]

tx=TransactionImpl:XidImpl [FormatId=257,

GlobalId=www.matchem.com//540019, BranchQual=]

synched=null timeout=5000 queue=[]

2003-08-24 03:54:38,692 ERROR

[org.jboss.ejb.plugins.LogInterceptor]

TransactionRolledbackLocalException, causedBy:

java.lang.IllegalStateException: removing bean lock and

it has tx set!

        at

org.jboss.ejb.plugins.lock.QueuedPessimisticEJBLock.removeRef(QueuedPessimisticEJBLock.java:430)

        at

org.jboss.ejb.BeanLockManager.removeLockRef(BeanLockManager.java:107)

        at

org.jboss.ejb.plugins.EntityLockInterceptor.invoke(EntityLockInterceptor.java:106)

        at

org.jboss.ejb.plugins.EntityCreationInterceptor.invoke(EntityCreationInterceptor.java:53)

        at

org.jboss.ejb.plugins.AbstractTxInterceptor.invokeNext(AbstractTxInterceptor.java:84)

        at

org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:273)

        at

org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:104)

        at

org.jboss.ejb.plugins.SecurityInterceptor.invoke(SecurityInterceptor.java:117)

        at

org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:191)

        at

org.jboss.ejb.plugins.ProxyFactoryFinderInterceptor.invoke(ProxyFactoryFinderInterceptor.java:122)

        at

org.jboss.ejb.EntityContainer.internalInvoke(EntityContainer.java:483)

        at

org.jboss.ejb.Container.invoke(Container.java:674)

        at

org.jboss.ejb.plugins.local.BaseLocalProxyFactory.invoke(BaseLocalProxyFactory.java:353)

        at

org.jboss.ejb.plugins.local.EntityProxy.invoke(EntityProxy.java:38)

        at $Proxy170.getRealName(Unknown Source)

        at

com.matchem.mitv.common.tvchat.TVChatShowComponentBean.getNewChatEntries(TVChatShowComponentBean.java:273)

        at

sun.reflect.GeneratedMethodAccessor63.invoke(Unknown

Source)

        at

sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)

        at java.lang.reflect.Method.invoke(Method.java:324)

        at

org.jboss.ejb.StatefulSessionContainer$ContainerInterceptor.invoke(StatefulSessionContainer.java:878)

        at

org.jboss.ejb.plugins.SecurityInterceptor.invoke(SecurityInterceptor.java:117)

        at

org.jboss.resource.connectionmanager.CachedConnectionInterceptor.invoke(CachedConnectionInterceptor.java:186)

        at

org.jboss.ejb.plugins.StatefulSessionInstanceInterceptor.invoke(StatefulSessionInstanceInterceptor.java:271)

        at

org.jboss.ejb.plugins.AbstractTxInterceptor.invokeNext(AbstractTxInterceptor.java:84)

        at

org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:243)

        at

org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:104)

        at

org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:191)

        at

org.jboss.ejb.plugins.ProxyFactoryFinderInterceptor.invoke(ProxyFactoryFinderInterceptor.java:122)

        at

org.jboss.ejb.StatefulSessionContainer.internalInvoke(StatefulSessionContainer.java:410)

        at

org.jboss.ejb.Container.invoke(Container.java:674)

        at

sun.reflect.GeneratedMethodAccessor50.invoke(Unknown

Source)

        at

sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)

        at java.lang.reflect.Method.invoke(Method.java:324)

        at

org.jboss.mx.capability.ReflectedMBeanDispatcher.invoke(ReflectedMBeanDispatcher.java:284)

        at

org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:549)

        at

org.jboss.invocation.http.server.HttpInvoker.invoke(HttpInvoker.java:163)

        at

sun.reflect.GeneratedMethodAccessor62.invoke(Unknown

Source)

        at

sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)

        at java.lang.reflect.Method.invoke(Method.java:324)

        at

org.jboss.mx.capability.ReflectedMBeanDispatcher.invoke(ReflectedMBeanDispatcher.java:284)

        at

org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:549)

        at

org.jboss.invocation.http.servlet.InvokerServlet.processRequest(InvokerServlet.java:132)

        at

org.jboss.invocation.http.servlet.InvokerServlet.doPost(InvokerServlet.java:171)

        at

javax.servlet.http.HttpServlet.service(HttpServlet.java:760)

        at

javax.servlet.http.HttpServlet.service(HttpServlet.java:853)

        at

org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:360)

        at

org.mortbay.jetty.servlet.WebApplicationHandler.dispatch(WebApplicationHandler.java:294)

        at

org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:558)

        at

org.mortbay.http.HttpContext.handle(HttpContext.java:1714)

        at

org.mortbay.jetty.servlet.WebApplicationContext.handle(WebApplicationContext.java:507)

        at

org.mortbay.http.HttpContext.handle(HttpContext.java:1664)

        at

org.mortbay.http.HttpServer.service(HttpServer.java:863)

        at org.jboss.jetty.Jetty.service(Jetty.java:460)

        at

org.mortbay.http.HttpConnection.service(HttpConnection.java:775)

        at

org.mortbay.http.HttpConnection.handleNext(HttpConnection.java:939)

        at

org.mortbay.http.HttpConnection.handle(HttpConnection.java:792)

        at

org.mortbay.http.SocketListener.handleConnection(SocketListener.java:201)

        at

org.mortbay.util.ThreadedServer.handle(ThreadedServer.java:289)

        at

org.mortbay.util.ThreadPool$PoolThread.run(ThreadPool.java:455)



----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=376685&aid=796177&group_id=22866


-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
_______________________________________________
JBoss-Development mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-development

Reply via email to