• Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: Medium Medium
    • None
    • 1.0.7
    • None
    • None
    • Application Server: Apache Tomcat/5.5.20
      Database Dialect: org.hibernate.dialect.MySQLDialect
      Version: 1.0.7
      Build Number: 111
      Build Date: May 10, 2007

      Every few hours Crowd is locking up.. We are getting the below exception. It comes right by itself after just a minute or two.. We have recently upgraded from .44 to 1.0.7 and didn't have any errors before this.. Its possible this is a red-herring though because the error looks like its coming out of MySQL.

      Damon.

      11:55:17,468 ERROR org.hibernate.event.def.AbstractFlushingEventListener: Could not synchronize database state with session
      org.hibernate.exception.GenericJDBCException: could not update: com.atlassian.crowd.model.token.Token#163844
      at org.hibernate.exception.SQLStateConverter.handledNonSpecificException(SQLStateConverter.java:103)
      at org.hibernate.exception.SQLStateConverter.convert(SQLStateConverter.java:91)
      at org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:43)
      at org.hibernate.persister.entity.AbstractEntityPersister.update(AbstractEntityPersister.java:2421)
      at org.hibernate.persister.entity.AbstractEntityPersister.updateOrInsert(AbstractEntityPersister.java:2303)
      at org.hibernate.persister.entity.AbstractEntityPersister.update(AbstractEntityPersister.java:2603)
      at org.hibernate.action.EntityUpdateAction.execute(EntityUpdateAction.java:92)
      at org.hibernate.engine.ActionQueue.execute(ActionQueue.java:248)
      at org.hibernate.engine.ActionQueue.executeActions(ActionQueue.java:232)
      at org.hibernate.engine.ActionQueue.executeActions(ActionQueue.java:140)
      at org.hibernate.event.def.AbstractFlushingEventListener.performExecutions(AbstractFlushingEventListener.java:298)
      at org.hibernate.event.def.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:27)
      at org.hibernate.impl.SessionImpl.flush(SessionImpl.java:1000)
      at org.springframework.orm.hibernate3.HibernateTemplate$29.doInHibernate(HibernateTemplate.java:815)
      at org.springframework.orm.hibernate3.HibernateTemplate.execute(HibernateTemplate.java:366)
      at org.springframework.orm.hibernate3.HibernateTemplate.flush(HibernateTemplate.java:813)
      at com.atlassian.crowd.util.persistence.hibernate.HibernateDao.update(HibernateDao.java:40)
      at com.atlassian.crowd.model.token.TokenDAOHibernate.update(TokenDAOHibernate.java:55)
      at com.atlassian.crowd.manager.GenericManager.genericValidateToken(GenericManager.java:134)
      at com.atlassian.crowd.manager.application.ApplicationManagerGeneric.validateToken(ApplicationManagerGeneric.java:100)
      at com.atlassian.crowd.service.soap.SOAPService.validateSOAPService(SOAPService.java:70)
      at com.atlassian.crowd.service.soap.SecurityServerGeneric.findPrincipalByName(SecurityServerGeneric.java:326)
      at sun.reflect.GeneratedMethodAccessor154.invoke(Unknown Source)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
      at java.lang.reflect.Method.invoke(Unknown Source)
      at org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:287)
      at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:181)
      at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:148)
      at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:96)
      at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:170)
      at org.springframework.orm.hibernate3.HibernateInterceptor.invoke(HibernateInterceptor.java:88)
      at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:170)
      at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:176)
      at $Proxy5.findPrincipalByName(Unknown Source)
      at sun.reflect.GeneratedMethodAccessor154.invoke(Unknown Source)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
      at java.lang.reflect.Method.invoke(Unknown Source)
      at org.codehaus.xfire.service.invoker.AbstractInvoker.invoke(AbstractInvoker.java:54)
      at org.codehaus.xfire.service.binding.ServiceInvocationHandler.sendMessage(ServiceInvocationHandler.java:271)
      at org.codehaus.xfire.service.binding.ServiceInvocationHandler$1.run(ServiceInvocationHandler.java:84)
      at org.codehaus.xfire.service.binding.ServiceInvocationHandler.execute(ServiceInvocationHandler.java:132)
      at org.codehaus.xfire.service.binding.ServiceInvocationHandler.invoke(ServiceInvocationHandler.java:107)
      at org.codehaus.xfire.handler.HandlerPipeline.invoke(HandlerPipeline.java:131)
      at org.codehaus.xfire.transport.DefaultEndpoint.onReceive(DefaultEndpoint.java:64)
      at org.codehaus.xfire.transport.AbstractChannel.receive(AbstractChannel.java:38)
      at org.codehaus.xfire.transport.http.XFireServletController.invoke(XFireServletController.java:287)
      at org.codehaus.xfire.transport.http.XFireServletController.doService(XFireServletController.java:130)
      at org.codehaus.xfire.transport.http.XFireServlet.doPost(XFireServlet.java:116)
      at javax.servlet.http.HttpServlet.service(HttpServlet.java:709)
      at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
      at org.springframework.orm.hibernate3.support.OpenSessionInViewFilter.doFilterInternal(OpenSessionInViewFilter.java:174)
      at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:77)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
      at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
      at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
      at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
      at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
      at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
      at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
      at org.apache.coyote.http11.Http11AprProcessor.process(Http11AprProcessor.java:833)
      at org.apache.coyote.http11.Http11AprProtocol$Http11ConnectionHandler.process(Http11AprProtocol.java:639)
      at org.apache.tomcat.util.net.AprEndpoint$Worker.run(AprEndpoint.java:1285)
      at java.lang.Thread.run(Unknown Source)
      Caused by: java.sql.SQLException: Lock wait timeout exceeded; try restarting transaction
      at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:2928)
      at com.mysql.jdbc.MysqlIO.sendCommand(MysqlIO.java:1571)
      at com.mysql.jdbc.ServerPreparedStatement.serverExecute(ServerPreparedStatement.java:1124)
      at com.mysql.jdbc.ServerPreparedStatement.executeInternal(ServerPreparedStatement.java:676)
      at com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:1166)
      at com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:1082)
      at com.mysql.jdbc.PreparedStatement.executeUpdate(PreparedStatement.java:1067)
      at org.apache.tomcat.dbcp.dbcp.DelegatingPreparedStatement.executeUpdate(DelegatingPreparedStatement.java:101)
      at org.hibernate.jdbc.NonBatchingBatcher.addToBatch(NonBatchingBatcher.java:23)
      at org.hibernate.persister.entity.AbstractEntityPersister.update(AbstractEntityPersister.java:2399)
      ... 62 more

            [CWD-324] Intermittent "Lock wait timeout exceeded" errors

            CWD-758 is the master issue for this.

            David O'Flynn [Atlassian] added a comment - CWD-758 is the master issue for this.

            Here are the details

            1. mysql Ver 14.12 Distrib 5.0.27, for Win32 (ia32) TC is using mysql-connector-java-3.1.12-bin.jar
            2. Session timeout is 500
            3. Its our Jira install causing the prob.

            Damon.

            Damon Rand added a comment - Here are the details 1. mysql Ver 14.12 Distrib 5.0.27, for Win32 (ia32) TC is using mysql-connector-java-3.1.12-bin.jar 2. Session timeout is 500 3. Its our Jira install causing the prob. Damon.

            Damon,

            Could you answer a few quick questions about this one?

            • Which version of MySQL are you using?
            • How long are your sessions configured to be valid for?
            • Which application is integrated that is causing this problem?

            Cheers,

            Justen

            Justen Stepka [Atlassian] added a comment - - edited Damon, Could you answer a few quick questions about this one? Which version of MySQL are you using? How long are your sessions configured to be valid for? Which application is integrated that is causing this problem? Cheers, Justen

              justen.stepka@atlassian.com Justen Stepka [Atlassian]
              65037adbeda8 Damon Rand
              Affected customers:
              0 This affects my team
              Watchers:
              2 Start watching this issue

                Created:
                Updated:
                Resolved: