2011-05-09 68 views
2

我得到UnexpectedRollbackException。以下是完整的堆棧跟蹤:JTA事務意外回退,嵌套異常是javax.transaction.RollbackException

org.springframework.transaction.UnexpectedRollbackException: JTA transaction unexpectedly rolled back (maybe due to a timeout); nested exception is javax.transaction.RollbackException 
    at org.springframework.transaction.jta.JtaTransactionManager.doCommit(JtaTransactionManager.java:1031) 
    at org.springframework.transaction.support.AbstractPlatformTransactionManager.processCommit(AbstractPlatformTransactionManager.java:732) 
    at org.springframework.transaction.support.AbstractPlatformTransactionManager.commit(AbstractPlatformTransactionManager.java:701) 
    at org.springframework.transaction.interceptor.TransactionAspectSupport.commitTransactionAfterReturning(TransactionAspectSupport.java:321) 
    at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:116) 
    at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171) 
    at org.springframework.aop.framework.Cglib2AopProxy$DynamicAdvisedInterceptor.intercept(Cglib2AopProxy.java:635) 
    at com.cmates.userIcon.service.IconUpdaterServiceImpl$$EnhancerByCGLIB$$78838aa7.persist(<generated>) 
    at com.cmates.userIcon.service.ScheduledIconUpdaterServiceImpl.doScheduledTask(ScheduledIconUpdaterServiceImpl.java:125) 
    at com.cmates.profile.services.IconSyncSingletonImpl.process(IconSyncSingletonImpl.java:121) 
    at com.cmates.profile.services.IconSyncJob.executeInternal(IconSyncJob.java:25) 
    at org.springframework.scheduling.quartz.QuartzJobBean.execute(QuartzJobBean.java:86) 
    at org.quartz.core.JobRunShell.run(JobRunShell.java:202) 
    at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:525) 
Caused by: javax.transaction.RollbackException 
    at org.objectweb.jotm.TransactionImpl.commit(TransactionImpl.java:245) 
    at org.objectweb.jotm.Current.commit(Current.java:488) 
    at org.springframework.transaction.jta.JtaTransactionManager.doCommit(JtaTransactionManager.java:1028) 
    ... 13 more 
[18 Apr 2011 00:54:00,590] ERROR ErrorLogger - Job (DEFAULT.iconSyncJob threw an exception. 

此異常突然開始顯示在我的日誌中。我沒有對我的代碼做任何改變。
我想這可能是由於超時?

回答

0

我在堆棧跟蹤中看到提到一個石英工作。看起來有些東西已經設置了定期工作,並且AOP交易管理已經找到了它。

0

它看起來像你的交易持續時間超過交易超時限制。你應該增加事務超時限制。

但我不確定,你應該發佈更多堆棧跟蹤來理解回滾的原因。

相關問題