-
1. Re: simple UserTransaction question
aloubyansky Jul 23, 2004 2:34 AM (in response to smilidon)JBoss returns the results the driver returned. So it means the query resulted in no results. Try writting a JDBC test.
-
2. Re: simple UserTransaction question
smilidon Jul 23, 2004 7:43 AM (in response to smilidon)thanks a lot. you mean i should test JDBC with a simple query on clientside with JDBC driver for mysql(in my case)?
some more information:
if i exit before i commit() the usertransaction and make a second query after restarting the client, i get this WARN after a while:
13:26:39,815 WARN [AbstractInstanceCache] Unable to passivate due to ctx lock, id=297
if i make the second query it looks like this:
13:28:33,768 DEBUG [Minfo#findByName] Executing SQL: SELECT ... ASC
13:28:33,768 DEBUG [LocalManagedConnectionFactory] Using properties: {user=root,
password=--hidden--}
thanks a lot for your help -
3. Re: simple UserTransaction question
smilidon Jul 23, 2004 7:49 AM (in response to smilidon)i also get this exeption because of the second query:
13:33:33,658 WARN [TransactionImpl] Transaction TransactionImpl:XidImpl [Format
Id=257, GlobalId=IVOHMEJ//68, BranchQual=] timed out. status=STATUS_ACTIVE
13:33:33,674 ERROR [BeanLock] Thread[RMI TCP Connection(30)-172.20.15.13,5,RMI R
untime]Saw rolled back tx=TransactionImpl:XidImpl [FormatId=257, GlobalId=IVOHME
J//68, BranchQual=] waiting for txLock
13:33:33,674 ERROR [LogInterceptor] TransactionRolledbackException in method: pu
blic abstract java.lang.Integer com.de.mediadb.cmp.Minfo.getId() throws java.rmi
.RemoteException, causedBy:
java.lang.RuntimeException: Transaction marked for rollback, possibly a timeout
at org.jboss.ejb.plugins.lock.QueuedPessimisticEJBLock.waitForTx(QueuedP
essimisticEJBLock.java:366)
at org.jboss.ejb.plugins.lock.QueuedPessimisticEJBLock.doSchedule(Queued
PessimisticEJBLock.java:236)
at org.jboss.ejb.plugins.lock.QueuedPessimisticEJBLock.schedule(QueuedPe
ssimisticEJBLock.java:183)
at org.jboss.ejb.plugins.EntityLockInterceptor.invoke(EntityLockIntercep
tor.java:85)
at org.jboss.ejb.plugins.EntityCreationInterceptor.invoke(EntityCreation
Interceptor.java:54)
at org.jboss.ejb.plugins.AbstractTxInterceptor.invokeNext(AbstractTxInte
rceptor.java:84)
at org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxIntercep
torCMT.java:315)
at org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:1
48)
at org.jboss.ejb.plugins.SecurityInterceptor.invoke(SecurityInterceptor.
java:120)
at org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:191)
at org.jboss.ejb.plugins.ProxyFactoryFinderInterceptor.invoke(ProxyFacto
ryFinderInterceptor.java:122)
at org.jboss.ejb.EntityContainer.internalInvoke(EntityContainer.java:484
)
at org.jboss.ejb.Container.invoke(Container.java:723)
at sun.reflect.GeneratedMethodAccessor63.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at org.jboss.mx.server.ReflectedDispatcher.dispatch(ReflectedDispatcher.
java:60)
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:61)
at org.jboss.mx.server.Invocation.dispatch(Invocation.java:53)
at org.jboss.mx.server.Invocation.invoke(Invocation.java:86)
at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.
java:185)
at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:473)
at org.jboss.invocation.jrmp.server.JRMPInvoker.invoke(JRMPInvoker.java:
360)
at sun.reflect.GeneratedMethodAccessor62.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:261)
at sun.rmi.transport.Transport$1.run(Transport.java:148)
at java.security.AccessController.doPrivileged(Native Method)
at sun.rmi.transport.Transport.serviceCall(Transport.java:144)
at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:4
60)
at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport
.java:701)
at java.lang.Thread.run(Thread.java:534) -
4. Re: simple UserTransaction question
aloubyansky Jul 24, 2004 2:23 AM (in response to smilidon)You should commit or rollback the transaction to release the lock on the instance.