[jboss-user] [Messaging, JMS & JBossMQ] - Re: Unique Constraint Error sending JMS Messages
dilshat
do-not-reply at jboss.com
Wed Nov 29 11:16:40 EST 2006
We have got the same problem here after running the JBoss 4.0.5 for for several days.
java.sql.SQLException: Unique constraint violation: in statement [INSERT INTO JMS_MESSAGES (MESSAGEID, DESTINATION, MESSAGEBLOB, TXID, TXOP) VALUES(?,?,?,?,?)]
Apparantly, the persistent manager is generating the same message ID (reference 3294537 msg=39626) until we have restarted the JBoss. I will be very grateful if you can tell me How the JMS message ID/reference is generated before persisting it into the database. I don't understand why all the JMS Messages to be persisted are stucked with the same ID.
| org.jboss.mq.SpyJMSException: Could not store message: 3294537 msg=39626 hard NOT_STORED NON_PERSISTENT queue=TOPIC.phoenix/FleetSchedulingServiceTopic.ID:3634.-2147483635 priority=1 lateClone=false hashCode=4627871; - nested throwable: (java.sql.SQLException: Unique constraint violation: in statement [INSERT INTO JMS_MESSAGES (MESSAGEID, DESTINATION, MESSAGEBLOB, TXID, TXOP) VALUES(?,?,?,?,?)])
| org.jboss.mq.SpyJMSException: Could not store message: 3294537 msg=39626 hard NOT_STORED NON_PERSISTENT queue=TOPIC.phoenix/FleetSchedulingServiceTopic.ID:3634.-2147483635 priority=1 lateClone=false hashCode=4627871; - nested throwable: (java.sql.SQLException: Unique constraint violation: in statement [INSERT INTO JMS_MESSAGES (MESSAGEID, DESTINATION, MESSAGEBLOB, TXID, TXOP) VALUES(?,?,?,?,?)])
| at org.jboss.mq.pm.jdbc2.PersistenceManager.saveToStorage(PersistenceManager.java:1646)
| at org.jboss.mq.server.MessageCache.saveToStorage(MessageCache.java:420)
| at org.jboss.mq.server.MessageReference.makeSoft(MessageReference.java:312)
| at org.jboss.mq.server.MessageCache.validateSoftReferenceDepth(MessageCache.java:367)
| at org.jboss.mq.server.MessageCache.addInternal(MessageCache.java:158)
| at org.jboss.mq.server.MessageCache.add(MessageCache.java:128)
| at org.jboss.mq.server.JMSTopic.addMessage(JMSTopic.java:416)
| at org.jboss.mq.server.JMSDestinationManager.addMessage(JMSDestinationManager.java:415)
| at org.jboss.mq.server.JMSDestinationManager.addMessage(JMSDestinationManager.java:399)
| at org.jboss.mq.server.JMSServerInterceptorSupport.addMessage(JMSServerInterceptorSupport.java:106)
| at org.jboss.mq.security.ServerSecurityInterceptor.addMessage(ServerSecurityInterceptor.java:168)
| at org.jboss.mq.server.TracingInterceptor.addMessage(TracingInterceptor.java:226)
| at org.jboss.mq.server.JMSServerInvoker.addMessage(JMSServerInvoker.java:112)
| at org.jboss.mq.il.jvm.JVMServerIL.addMessage(JVMServerIL.java:101)
| at org.jboss.mq.Connection.sendToServer(Connection.java:918)
| at org.jboss.mq.SpySession.sendMessage(SpySession.java:924)
| at org.jboss.mq.SpyMessageProducer.send(SpyMessageProducer.java:272)
| at org.jboss.mq.SpyMessageProducer.send(SpyMessageProducer.java:219)
| at org.jboss.mq.SpyTopicPublisher.publish(SpyTopicPublisher.java:67)
| at com.phoenix.booking.j2ee.beans.session.FleetSchedulingServiceSession.sendMessage(FleetSchedulingServiceSession.java:495)
| at com.phoenix.booking.j2ee.beans.session.FleetSchedulingServiceSession.updateFullSchedulerJob(FleetSchedulingServiceSession.java:300)
| at com.phoenix.booking.j2ee.beans.session.FleetSchedulingServiceBean.updateManyJobs(FleetSchedulingServiceBean.java:1846)
| at sun.reflect.GeneratedMethodAccessor958.invoke(Unknown Source)
| at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
| at java.lang.reflect.Method.invoke(Method.java:585)
| 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.AbstractTxInterceptor.invokeNext(AbstractTxInterceptor.java:121)
| at org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:350)
| 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:136)
| at org.jboss.ejb.SessionContainer.internalInvoke(SessionContainer.java:648)
| at org.jboss.ejb.Container.invoke(Container.java:954)
| at sun.reflect.GeneratedMethodAccessor283.invoke(Unknown Source)
| at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
| at java.lang.reflect.Method.invoke(Method.java:585)
| 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.invocation.local.LocalInvoker$MBeanServerAction.invoke(LocalInvoker.java:169)
| at org.jboss.invocation.local.LocalInvoker.invoke(LocalInvoker.java:118)
| at org.jboss.invocation.InvokerInterceptor.invokeLocal(InvokerInterceptor.java:209)
| at org.jboss.invocation.InvokerInterceptor.invoke(InvokerInterceptor.java:195)
| at org.jboss.proxy.TransactionInterceptor.invoke(TransactionInterceptor.java:61)
| at org.jboss.proxy.SecurityInterceptor.invoke(SecurityInterceptor.java:70)
| at org.jboss.proxy.ejb.StatelessSessionInterceptor.invoke(StatelessSessionInterceptor.java:112)
| at org.jboss.proxy.ClientContainer.invoke(ClientContainer.java:100)
| at $Proxy297.updateManyJobs(Unknown Source)
| at com.phoenix.booking.services.FleetSchedulingServiceImpl.updateManyJobs(FleetSchedulingServiceImpl.java:711)
| at com.phoenix.services.scheduler.SchedulingEngine.writeManyJobsToDatabase(SchedulingEngine.java:303)
| at com.phoenix.services.scheduler.SchedulingEngine.writeDirtyJobs(SchedulingEngine.java:274)
| at com.phoenix.services.scheduler.SchedulingEngine.run(SchedulingEngine.java:145)
| at java.lang.Thread.run(Thread.java:595)
| Caused by: java.sql.SQLException: Unique constraint violation: in statement [INSERT INTO JMS_MESSAGES (MESSAGEID, DESTINATION, MESSAGEBLOB, TXID, TXOP) VALUES(?,?,?,?,?)]
| at org.hsqldb.jdbc.Util.throwError(Unknown Source)
| at org.hsqldb.jdbc.jdbcPreparedStatement.executeUpdate(Unknown Source)
| at org.jboss.resource.adapter.jdbc.WrappedPreparedStatement.executeUpdate(WrappedPreparedStatement.java:251)
| at org.jboss.mq.pm.jdbc2.PersistenceManager.add(PersistenceManager.java:1136)
| at org.jboss.mq.pm.jdbc2.PersistenceManager.saveToStorage(PersistenceManager.java:1632)
| ... 58 more
|
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3989756#3989756
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3989756
More information about the jboss-user
mailing list