net.sf.hibernate.HibernateException: SQL update or deletion failed (row not found)

Hibernate JIRA | stephen brown | 1 decade ago
  1. 0

    I'm not sure if this is MySQL related or not, it occurs on the OpenSymphony Confluence instance trying to remove pages. org.springframework.orm.hibernate.HibernateSystemException: Flush during cascade is dangerous - this might occur if an object was deleted and then re-saved by cascade (remove deleted object from associations); nested exception is: net.sf.hibernate.HibernateException: Flush during cascade is dangerous - this might occur if an object was deleted and then re-saved by cascade (remove deleted object from associations) net.sf.hibernate.HibernateException: Flush during cascade is dangerous - this might occur if an object was deleted and then re-saved by cascade (remove deleted object from associations) at net.sf.hibernate.impl.SessionImpl.flush(SessionImpl.java:2174) at net.sf.hibernate.impl.SessionImpl.save(SessionImpl.java:711) at net.sf.hibernate.impl.SessionImpl.saveOrUpdate(SessionImpl.java:1319) at net.sf.hibernate.engine.Cascades$4.cascade(Cascades.java:114) at net.sf.hibernate.engine.Cascades.cascade(Cascades.java:436) at net.sf.hibernate.engine.Cascades.cascadeCollection(Cascades.java:526) at net.sf.hibernate.engine.Cascades.cascade(Cascades.java:452) at net.sf.hibernate.engine.Cascades.cascade(Cascades.java:503) at net.sf.hibernate.engine.Cascades.cascade(Cascades.java:482) at net.sf.hibernate.impl.SessionImpl.preFlushEntities(SessionImpl.java:2583) at net.sf.hibernate.impl.SessionImpl.flushEverything(SessionImpl.java:2190) at net.sf.hibernate.impl.SessionImpl.flush(SessionImpl.java:2179) at net.sf.hibernate.transaction.JDBCTransaction.commit(JDBCTransaction.java:61) at org.springframework.orm.hibernate.HibernateTransactionManager.doCommit(HibernateTransactionManager.java:309) at org.springframework.transaction.support.AbstractPlatformTransactionManager.commit(AbstractPlatformTransactionManager.java:218) at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:172) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:196) at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:135) at $Proxy83.removeContentEntity(Unknown Source) at com.atlassian.confluence.pages.actions.RemovePageAction.doRemove(RemovePageAction.java:45)

    Atlassian JIRA | 1 decade ago | Mike Cannon-Brookes
    net.sf.hibernate.HibernateException: Flush during cascade is dangerous - this might occur if an object was deleted and then re-saved by cascade (remove deleted object from associations)
  2. Speed up your debug routine!

    Automated exception search integrated into your IDE

  3. 0

    trying to remove this page http://confluence.atlassian.com/display/DISC/testing%2Bsearch produces this error : Cause: org.springframework.orm.hibernate.HibernateSystemException: Flush during cascade is dangerous - this might occur if an object was deleted and then re-saved by cascade (remove deleted object from associations); nested exception is: net.sf.hibernate.HibernateException: Flush during cascade is dangerous - this might occur if an object was deleted and then re-saved by cascade (remove deleted object from associations) Stack Trace: [hide] org.springframework.orm.hibernate.HibernateSystemException: Flush during cascade is dangerous - this might occur if an object was deleted and then re-saved by cascade (remove deleted object from associations); nested exception is: net.sf.hibernate.HibernateException: Flush during cascade is dangerous - this might occur if an object was deleted and then re-saved by cascade (remove deleted object from associations) net.sf.hibernate.HibernateException: Flush during cascade is dangerous - this might occur if an object was deleted and then re-saved by cascade (remove deleted object from associations) at net.sf.hibernate.impl.SessionImpl.flush(SessionImpl.java:2174) at net.sf.hibernate.impl.SessionImpl.save(SessionImpl.java:711) at net.sf.hibernate.impl.SessionImpl.saveOrUpdate(SessionImpl.java:1319) at net.sf.hibernate.engine.Cascades$4.cascade(Cascades.java:114) at net.sf.hibernate.engine.Cascades.cascade(Cascades.java:436) at net.sf.hibernate.engine.Cascades.cascadeCollection(Cascades.java:526) at net.sf.hibernate.engine.Cascades.cascade(Cascades.java:452) at net.sf.hibernate.engine.Cascades.cascade(Cascades.java:503) at net.sf.hibernate.engine.Cascades.cascade(Cascades.java:482) at net.sf.hibernate.impl.SessionImpl.preFlushEntities(SessionImpl.java:2583) at net.sf.hibernate.impl.SessionImpl.flushEverything(SessionImpl.java:2190) at net.sf.hibernate.impl.SessionImpl.flush(SessionImpl.java:2179) at net.sf.hibernate.transaction.JDBCTransaction.commit(JDBCTransaction.java:61) at org.springframework.orm.hibernate.HibernateTransactionManager.doCommit(HibernateTransactionManager.java:309) at org.springframework.transaction.support.AbstractPlatformTransactionManager.commit(AbstractPlatformTransactionManager.java:218) at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:172) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:196) at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:135) at $Proxy97.removeContentEntity(Unknown Source) at com.atlassian.confluence.pages.actions.RemovePageAction.doRemove(RemovePageAction.java:45) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:324) at com.opensymphony.xwork.DefaultActionInvocation.invokeAction(DefaultActionInvocation.java:309) at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:175) at com.opensymphony.xwork.interceptor.AroundInterceptor.intercept(AroundInterceptor.java:37) at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:170) at com.opensymphony.xwork.interceptor.DefaultWorkflowInterceptor.intercept(DefaultWorkflowInterceptor.java:58) at com.atlassian.confluence.core.ConfluenceWorkflowInterceptor.intercept(ConfluenceWorkflowInterceptor.java:32) at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:170) at com.opensymphony.xwork.interceptor.AroundInterceptor.intercept(AroundInterceptor.java:37) at com.atlassian.confluence.core.ConfluenceValidationInterceptor.intercept(ConfluenceValidationInterceptor.java:18) at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:170) at com.opensymphony.xwork.interceptor.AroundInterceptor.intercept(AroundInterceptor.java:37) at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:170) at com.atlassian.confluence.security.actions.PermissionCheckInterceptor.intercept(PermissionCheckInterceptor.java:40) at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:170) at com.opensymphony.xwork.interceptor.AroundInterceptor.intercept(AroundInterceptor.java:37) at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:170) at com.opensymphony.xwork.interceptor.AroundInterceptor.intercept(AroundInterceptor.java:37) at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:170) at com.opensymphony.xwork.interceptor.AroundInterceptor.intercept(AroundInterceptor.java:37) at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:170) at com.opensymphony.xwork.interceptor.AroundInterceptor.intercept(AroundInterceptor.java:37) at com.opensymphony.xwork.DefaultActionInvocation.invoke(DefaultActionInvocation.java:170) at com.opensymphony.xwork.DefaultActionProxy.execute(DefaultActionProxy.java:116) at com.opensymphony.webwork.dispatcher.ServletDispatcher.serviceAction(ServletDispatcher.java:182) at com.opensymphony.webwork.dispatcher.ServletDispatcher.service(ServletDispatcher.java:162) at javax.servlet.http.HttpServlet.service(HttpServlet.java:103) at com.caucho.server.http.FilterChainServlet.doFilter(FilterChainServlet.java:96) at com.opensymphony.module.sitemesh.filter.PageFilter.parsePage(PageFilter.java:129) at com.atlassian.confluence.util.profiling.ProfilingPageFilter.parsePage(ProfilingPageFilter.java:36) at com.opensymphony.module.sitemesh.filter.PageFilter.doFilter(PageFilter.java:61) at com.caucho.server.http.FilterChainFilter.doFilter(FilterChainFilter.java:88) at com.atlassian.seraph.filter.SecurityFilter.doFilter(SecurityFilter.java:161) at com.caucho.server.http.FilterChainFilter.doFilter(FilterChainFilter.java:88) at com.atlassian.seraph.filter.LoginFilter.doFilter(LoginFilter.java:181) at com.caucho.server.http.FilterChainFilter.doFilter(FilterChainFilter.java:88) at com.atlassian.johnson.filters.JohnsonFilter.doFilter(JohnsonFilter.java:96) at com.caucho.server.http.FilterChainFilter.doFilter(FilterChainFilter.java:88) at org.springframework.orm.hibernate.support.OpenSessionInViewFilter.doFilterInternal(OpenSessionInViewFilter.java:83) at com.atlassian.confluence.setup.SpringSessionInViewFilter.doFilterInternal(SpringSessionInViewFilter.java:32) at org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:39) at com.caucho.server.http.FilterChainFilter.doFilter(FilterChainFilter.java:88) at com.atlassian.util.profiling.filters.ProfilingFilter.doFilter(ProfilingFilter.java:132) at com.caucho.server.http.FilterChainFilter.doFilter(FilterChainFilter.java:88) at com.atlassian.core.filters.AbstractEncodingFilter.doFilter(AbstractEncodingFilter.java:38) at com.caucho.server.http.FilterChainFilter.doFilter(FilterChainFilter.java:88) at com.caucho.server.http.Invocation.service(Invocation.java:315) at com.caucho.server.http.HttpRequest.handleRequest(HttpRequest.java:246) at com.caucho.server.http.HttpRequest.handleConnection(HttpRequest.java:163) at com.caucho.server.TcpConnection.run(TcpConnection.java:139) at java.lang.Thread.run(Thread.java:534) Referer URL: http://confluence.atlassian.com/pages/removepage.action?spaceKey=DISC&title=testing+search System Information: System Date: Wednesday, 28 Jan 2004

    Atlassian JIRA | 1 decade ago | Zohar Melamed
    net.sf.hibernate.HibernateException: Flush during cascade is dangerous - this might occur if an object was deleted and then re-saved by cascade (remove deleted object from associations)
  4. 0

    I get this exception when trying to edit my personal description: org.springframework.orm.hibernate.HibernateSystemException: Found shared references to a collection; nested exception is: net.sf.hibernate.HibernateException: Found shared references to a collection net.sf.hibernate.HibernateException: Found shared references to a collection at net.sf.hibernate.impl.SessionImpl.updateReachableCollection(SessionImpl.java:2785) at net.sf.hibernate.impl.FlushVisitor.processCollection(FlushVisitor.java:63) at net.sf.hibernate.impl.AbstractVisitor.processValue(AbstractVisitor.java:137) at net.sf.hibernate.impl.AbstractVisitor.processValues(AbstractVisitor.java:71) at net.sf.hibernate.impl.SessionImpl.flushEntity(SessionImpl.java:2500) at net.sf.hibernate.impl.SessionImpl.flushEntities(SessionImpl.java:2366) at net.sf.hibernate.impl.SessionImpl.flushEverything(SessionImpl.java:2200) at net.sf.hibernate.impl.SessionImpl.flush(SessionImpl.java:2179) at net.sf.hibernate.transaction.JDBCTransaction.commit(JDBCTransaction.java:61) at org.springframework.orm.hibernate.HibernateTransactionManager.doCommit(HibernateTransactionManager.java:309) at org.springframework.transaction.support.AbstractPlatformTransactionManager.commit(AbstractPlatformTransactionManager.java:218) at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:172) at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:196) at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:135) at $Proxy6.savePersonalInformation(Unknown Source) at com.atlassian.confluence.user.actions.EditMyProfileAction.updatePersonalInformation(EditMyProfileAction.java:113) at com.atlassian.confluence.user.actions.EditMyProfileAction.doEdit(EditMyProfileAction.java:70)

    Atlassian JIRA | 1 decade ago | Mike Cannon-Brookes
    net.sf.hibernate.HibernateException: Found shared references to a collection

    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    Root Cause Analysis

    1. net.sf.hibernate.HibernateException

      SQL update or deletion failed (row not found)

      at net.sf.hibernate.impl.NonBatchingBatcher.addToBatch()
    2. net.sf.hibernate
      JDBCTransaction.commit
      1. net.sf.hibernate.impl.NonBatchingBatcher.addToBatch(NonBatchingBatcher.java:25)
      2. net.sf.hibernate.persister.EntityPersister.update(EntityPersister.java:672)
      3. net.sf.hibernate.persister.EntityPersister.update(EntityPersister.java:625)
      4. net.sf.hibernate.impl.ScheduledUpdate.execute(ScheduledUpdate.java:52)
      5. net.sf.hibernate.impl.SessionImpl.executeAll(SessionImpl.java:2308)
      6. net.sf.hibernate.impl.SessionImpl.execute(SessionImpl.java:2262)
      7. net.sf.hibernate.impl.SessionImpl.flush(SessionImpl.java:2187)
      8. net.sf.hibernate.transaction.JDBCTransaction.commit(JDBCTransaction.java:61)
      8 frames