[jboss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Could not enlist in transaction on entering meta-aware objec

jeff_porter do-not-reply at jboss.com
Thu Apr 10 06:48:49 EDT 2008


Hello all,

I'm really really stuck on a persistence issue and would like some help please.

jboss-4.2.2.GA
Hibernate 3
MySQL 5.0

I have an EJB that is a SessionBean & TimedObject.

It wakes up every 200 ms to check a directory for any files to process.
(XML files)

I'm using a <local-tx-datasource>.
I've tried using <no-tx-datasource>, but not all the data gets saved to the DB (no error messages).

The EJB has no static member varibles.
The EJB makes a call to another EJB to do the actual persistence.

This is the statck trace I get...



  | 11:34:26,468 WARN  [loggerI18N] [com.arjuna.ats.internal.jta.transaction.arjunacore.lastResource.disallow] [com.arjuna.ats.internal.jta.transaction.arjunacore.lastResource.disallow] Adding multiple last resources is disallowed. Current resource is org.jboss.resource.connectionmanager.TxConnectionManager$LocalXAResource at a488b9
  | 11:34:26,515 ERROR [LogInterceptor] EJBException in method: public abstract void javax.ejb.TimedObject.ejbTimeout(javax.ejb.Timer), causedBy
  | :
  | java.lang.IllegalStateException: Unable to persist timer
  |         at org.jboss.ejb.txtimer.DatabasePersistencePolicy.insertTimer(DatabasePersistencePolicy.java:124)
  |         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 org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:155)
  |         at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94)
  |         at org.jboss.mx.server.Invocation.invoke(Invocation.java:86)
  |         at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264)
  |         at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)
  |         at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:210)
  |         at $Proxy29.insertTimer(Unknown Source)
  |         at org.jboss.ejb.txtimer.TimerServiceImpl.createTimer(TimerServiceImpl.java:256)
  |         at org.jboss.ejb.txtimer.TimerServiceImpl.createTimer(TimerServiceImpl.java:171)
  |         at org.jboss.ejb.StatelessSessionEnterpriseContext$TimerServiceWrapper.createTimer(StatelessSessionEnterpriseContext.java:280)
  |         at com.kbtflawt.server.ejb.DirectoryPoller.ejbTimeout(DirectoryPoller.java:247)
  |         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 org.jboss.invocation.Invocation.performCall(Invocation.java:359)
  |         at org.jboss.ejb.StatelessSessionContainer$ContainerInterceptor.invoke(StatelessSessionContainer.java:237)
  |         at org.jboss.resource.connectionmanager.CachedConnectionInterceptor.invoke(CachedConnectionInterceptor.java:158)
  |         at org.jboss.ejb.plugins.StatelessSessionInstanceInterceptor.invoke(StatelessSessionInstanceInterceptor.java:169)
  |         at org.jboss.ejb.plugins.CallValidationInterceptor.invoke(CallValidationInterceptor.java:63)
  |         at org.jboss.ejb.plugins.AbstractTxInterceptor.invokeNext(AbstractTxInterceptor.java:121)
  |         at org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:404)
  |         at org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:181)
  |         at org.jboss.ejb.plugins.SecurityInterceptor.invoke(SecurityInterceptor.java:168)
  |         at org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:205)
  |         at org.jboss.ejb.plugins.ProxyFactoryFinderInterceptor.invoke(ProxyFactoryFinderInterceptor.java:138)
  |         at org.jboss.ejb.SessionContainer.internalInvoke(SessionContainer.java:648)
  |         at org.jboss.ejb.Container.invoke(Container.java:960)
  |         at org.jboss.ejb.txtimer.TimedObjectInvokerImpl.callTimeout(TimedObjectInvokerImpl.java:99)
  |         at org.jboss.ejb.txtimer.TimerImpl$TimerTaskImpl.run(TimerImpl.java:561)
  |         at java.util.TimerThread.mainLoop(Timer.java:512)
  |         at java.util.TimerThread.run(Timer.java:462)
  | Caused by: org.jboss.util.NestedSQLException: Could not enlist in transaction on entering meta-aware object!; - nested throwable: (javax.transaction.SystemException: java.lang.Throwable: Unabled to enlist resource, see the previous warnings. tx=TransactionImple < ac, BasicAction:
  |  -3f57fffe:884:47fdecfb:3566 status: ActionStatus.ABORT_ONLY >); - nested throwable: (org.jboss.resource.JBossResourceException: Could not enlist in transaction on entering meta-aware object!; - nested throwable: (javax.transaction.SystemException: java.lang.Throwable: Unabled to
  |  enlist resource, see the previous warnings. tx=TransactionImple < ac, BasicAction: -3f57fffe:884:47fdecfb:3566 status: ActionStatus.ABORT_ONLY >))
  |         at org.jboss.resource.adapter.jdbc.WrapperDataSource.getConnection(WrapperDataSource.java:94)
  |         at org.jboss.ejb.txtimer.GeneralPurposeDatabasePersistencePlugin.insertTimer(GeneralPurposeDatabasePersistencePlugin.java:199)
  |         at org.jboss.ejb.txtimer.DatabasePersistencePolicy.insertTimer(DatabasePersistencePolicy.java:120)
  |         ... 36 more
  | 11:34:26,609 ERROR [TimerImpl] Error invoking ejbTimeout: javax.ejb.EJBException: Failed to create timer
  | 
  | 
  | 

can someone give me some advice please?

thanks
Jeff

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4143125#4143125

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4143125



More information about the jboss-user mailing list