-
1. Re: Weird commit exception
vincent Jan 28, 2002 1:02 AM (in response to chenfang)Possibly you have a deadlock.
You have only one client running ?
Is RequiresNew used somewhere in the process ? -
2. Re: Weird commit exception
chenfang Jan 29, 2002 4:09 AM (in response to chenfang)Thanks, Vincent.
Seems like it is something associated with postgresql about how it handles null value ( in combination with different data type) for columns. I shuffled
aroud my code and it seems to be working. But I have another problem that I just posted.
If someone can answer that one, I would be very appreciated.
Thanks. -
3. Re: Weird commit exception
zerosleep Feb 24, 2002 4:43 PM (in response to chenfang)I'm having a similar error when trying to update a DATE field in PostgreSQL 7.2 via JBoss 3.0 (latest snapshot).
I'm simply passing a java.sql.Date to a setDateAdded method on my EJB. Anyone else have this problem? I verified the date is in the proper format. I'm totally lost on this one.
I get the following error:
14:36:27,062 ERROR [EntityContainer] invoke returned an exception
javax.transaction.RollbackException: Unable to commit, tx=XidImpl [FormatId=257, GlobalId=zerosleep1//38, BranchQual=] status=STATUS_ROLLEDBACK
at org.jboss.tm.TxCapsule.commit(TxCapsule.java:362)
at org.jboss.tm.TransactionImpl.commit(TransactionImpl.java:76)
at org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:173)
at org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:64)
at org.jboss.ejb.plugins.SecurityInterceptor.invoke(SecurityInterceptor.java:127)
at org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:166)
at org.jboss.ejb.EntityContainer.invoke(EntityContainer.java:435)
at org.jboss.ejb.Container.invoke(Container.java:609)
at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1555)
at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl.java:1523)
at org.jboss.invocation.local.LocalInvoker.invoke(LocalInvoker.java:113)
at org.jboss.invocation.jrmp.interfaces.JRMPInvokerProxy.invoke(JRMPInvokerProxy.java:149)
at org.jboss.proxy.ejb.GenericProxy.invoke(GenericProxy.java:182)
at org.jboss.proxy.ejb.EntityProxy.invoke(EntityProxy.java:134)
at $Proxy60.setLastLogin(Unknown Source)
at com.zerosleep.zscaddie.servlets.PlayerManagerServlet.updateLoginDate(PlayerManagerServlet.java:142)
at com.zerosleep.zscaddie.servlets.PlayerManagerServlet.processRequest(PlayerManagerServlet.java:45)
at com.zerosleep.zscaddie.servlets.PlayerManagerServlet.doGet(PlayerManagerServlet.java:52)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:327)
at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:546)
at org.mortbay.http.HttpContext.handle(HttpContext.java:1269)
at org.mortbay.http.HttpContext.handle(HttpContext.java:1223)
at org.mortbay.http.HttpServer.service(HttpServer.java:725)
at org.mortbay.http.HttpConnection.service(HttpConnection.java:748)
at org.mortbay.http.HttpConnection.handleNext(HttpConnection.java:921)
at org.mortbay.http.HttpConnection.handle(HttpConnection.java:763)
at org.mortbay.http.SocketListener.handleConnection(SocketListener.java:138)
at org.mortbay.util.ThreadedServer.handle(ThreadedServer.java:287)
at org.mortbay.util.ThreadPool$JobRunner.run(ThreadPool.java:715)
at java.lang.Thread.run(Unknown Source)
Here's my datasource service:
ConnectionURL=jdbc : postgresql://localhost:5432/MyTable
DriverClass=org.postgresql.Driver
UserName=postgres
Password=mypasswrd
pgsql-myds
java:/TransactionManager
<depends optional-attribute-name="ResourceAdapterName">jboss.jca:service=RARDeployment,name=Minerva JDBC LocalTransaction ResourceAdapter
<depends optional-attribute-name="ConnectionManagerFactoryLoaderName">jboss.jca:service=ConnectionManagerFactoryLoader,name=MinervaSharedLocalCMFactory
BlockingTimeoutMillis=500000
IdleTimeoutMinutes=30
MaxSize=10
CleanupIntervalMinutes=10
MinSize=0
MaxIdleTimeoutPercent=1.0
org.jboss.resource.security.ManyToOnePrincipalMapping
UserName=postgres
my remote interface method
public void setDateAdded(java.sql.Date aSQLDate) throws RemoteException;
os: windows 2000
jboss version: 3.0, latest snapshot
jdk version: 1.3.1
postgres version: 7.2 on cygwin 1.3.10
Any help would be much appreciated. -
4. Re: Weird commit exception
kuba.nowakowski Jul 4, 2002 10:37 AM (in response to chenfang)Hi
Have you solved this problem???
regards
Kuba -
5. Re: Weird commit exception
dsundstrom Jul 4, 2002 12:25 PM (in response to chenfang)Are you using the newest PostgreSQL drivers? PostgreSQL is the only other database I test against, so I am fairly confident it does work.
I did change many of the mappings for the date fields in jboss 3.0.1. If you have an existing table you may have to change the jdbc-type of the java.sql.Date to whatever it was in the last version you were using.
If this doesn't fix it, post the stacktrace for the caused by exception, which should be printed in the server.log file. -
6. Re: Weird commit exception
kuba.nowakowski Jul 5, 2002 8:46 AM (in response to chenfang)Hi
No
I'm using oracle 8.1.7
and jboss 3.0
Kuba -
7. Re: Weird commit exception
dsundstrom Jul 5, 2002 1:26 PM (in response to chenfang)Then you do not have the same problem. Please, start a new thread for your exact problem.