9 Replies Latest reply on Apr 4, 2008 10:38 AM by Anurag Paliwal

    org.hibernate.AssertionFailure: collection [org.jbpm.graph.d

    Syed Arshad Newbie

      Hi,

      I am trying to update the due date of a timer through my code and here is the step by step actions I have taken which is leading me to this exception:

      1. I am creating a timer through process defintion for a specific state
      2. When a enity business date changes, I need to modify the due date of the timer associated with this state.
      3. What I do when this business date is changed:
      a. I am find the specific timer using SchedulerSession and for the given token
      b. Update the due date for this timer and call the deleteTimer and saveTimer by passing the same object (since there is no update timer method).

      It is throwing this exception. We are using the spring modules for managing this transactions associated with hibernate and JBPM.

      Here is little more info about code:
      Process Defintion:

      <state name="state name">
       <event type="node-enter">
       <action name="action" class="org.springmodules.workflow.jbpm31.JbpmHandlerProxy">
       <targetBean>actionBeanName</targetBean>
       </action>
       </event>
       <transition name="name" to="another state"></transition>
       <timer name="lateTimer" duedate="1 days" transition="timeout"></timer>
       </state>


      and the java code:
      bpmTemplate.execute(new JbpmCallback() {
       public Object doInJbpm(JbpmContext context) {
       ProcessInstance processInstance = getProcessInstance(context, enity);
       if (processInstance != null) {
       Token token = processInstance.getRootToken();
       SchedulerSession schedulerSession = context.getSchedulerSession();
      List<Timer> timers = schedulerSession.findTimersByName(
      WorkflowProcessConstants.TIMER_NAME, token);
       Timer timer = timers.get(0);
      if(!TimeUtil.isSameDay(timer.getDueDate(), enityDate)){
       timer.setDueDate(entityDate);
       schedulerSession.deleteTimer(timer);
       schedulerSession.saveTimer(timer);


      and finally the stack trace:
      org.hibernate.AssertionFailure: collection [org.jbpm.graph.def.Node.leavingTransitions] was not processed by flush()
       org.hibernate.engine.CollectionEntry.postFlush(CollectionEntry.java:205)
       org.hibernate.event.def.AbstractFlushingEventListener.postFlush(AbstractFlushingEventListener.java:332)
       org.hibernate.event.def.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:28)
       org.hibernate.impl.SessionImpl.flush(SessionImpl.java:985)
       org.hibernate.impl.SessionImpl.managedFlush(SessionImpl.java:333)
       org.hibernate.transaction.JDBCTransaction.commit(JDBCTransaction.java:106)
       org.springframework.orm.hibernate3.HibernateTransactionManager.doCommit(HibernateTransactionManager.java:584)
       org.springframework.transaction.support.AbstractPlatformTransactionManager.processCommit(AbstractPlatformTransactionManager.java:496)
       org.springframework.transaction.support.AbstractPlatformTransactionManager.commit(AbstractPlatformTransactionManager.java:469)
       org.springframework.transaction.interceptor.TransactionAspectSupport.doCommitTransactionAfterReturning(TransactionAspectSupport.java:266)
       org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:106)
       org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:170)
       org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:176)
       $Proxy6.updateAndAdjustWorkflow(Unknown Source)
      Controller.onFormSubmit(Controller.java:178)
       AdminBaseFormController.onSubmit(AdminBaseFormController.java:130)
       org.springframework.web.servlet.mvc.SimpleFormController.processFormSubmission(SimpleFormController.java:258)
       org.springframework.web.servlet.mvc.AbstractFormController.handleRequestInternal(AbstractFormController.java:259)
       org.springframework.web.servlet.mvc.AbstractController.handleRequest(AbstractController.java:139)
       org.springframework.web.servlet.mvc.SimpleControllerHandlerAdapter.handle(SimpleControllerHandlerAdapter.java:44)
       org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:717)
       org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:658)
       org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:392)
       org.springframework.web.servlet.FrameworkServlet.doPost(FrameworkServlet.java:357)
       javax.servlet.http.HttpServlet.service(HttpServlet.java:709)
       javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
       org.donorschoose.web.filter.ActionFilter.doFilter(ActionFilter.java:112)
       org.springframework.orm.hibernate3.support.OpenSessionInViewFilter.doFilterInternal(OpenSessionInViewFilter.java:174)
       org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:76)
      
      
      note The full stack trace of the root cause is available in the Apache Tomcat/5.5.12 logs.





        • 1. Re: org.hibernate.AssertionFailure: collection [org.jbpm.gra
          Ronald van Kuijk Master

          The last line of the 'stacktrace' is important. Often (very often) the real stacktrace in the log contains more detailed info

          • 2. Re: org.hibernate.AssertionFailure: collection [org.jbpm.gra
            Syed Arshad Newbie

            OK, this should give more information on this, also, I just tried introducing the method update inside the schedulersession instead of deleting and creating a new one. But this also didn't help me.

            2007-01-03 13:21:08,924 DEBUG [org.springframework.orm.hibernate3.HibernateTransactionManager] - Committing Hibernate transaction on Session [org.hibernate.impl.SessionImpl@3e0b62]
            2007-01-03 13:21:08,924 DEBUG [org.hibernate.impl.SessionImpl] - automatically flushing session
            2007-01-03 13:21:08,944 DEBUG [org.hibernate.impl.SessionImpl] - initializing proxy: [org.jbpm.graph.node.State#745]
            2007-01-03 13:21:09,014 ERROR [org.hibernate.AssertionFailure] - an assertion failure occured (this may indicate a bug in Hibernate, but is more likely due to unsafe use of the session)
            org.hibernate.AssertionFailure: collection [org.jbpm.graph.def.Node.leavingTransitions] was not processed by flush()
             at org.hibernate.engine.CollectionEntry.postFlush(CollectionEntry.java:205)
             at org.hibernate.event.def.AbstractFlushingEventListener.postFlush(AbstractFlushingEventListener.java:332)
             at org.hibernate.event.def.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:28)
             at org.hibernate.impl.SessionImpl.flush(SessionImpl.java:985)
             at org.hibernate.impl.SessionImpl.managedFlush(SessionImpl.java:333)
             at org.hibernate.transaction.JDBCTransaction.commit(JDBCTransaction.java:106)
             at org.springframework.orm.hibernate3.HibernateTransactionManager.doCommit(HibernateTransactionManager.java:584)
             at org.springframework.transaction.support.AbstractPlatformTransactionManager.processCommit(AbstractPlatformTransactionManager.java:496)
             at org.springframework.transaction.support.AbstractPlatformTransactionManager.commit(AbstractPlatformTransactionManager.java:469)
             at org.springframework.transaction.interceptor.TransactionAspectSupport.doCommitTransactionAfterReturning(TransactionAspectSupport.java:266)
             at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:106)
             at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:170)
             at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:176)
             at $Proxy6.updateAndAdjustWorkflow(Unknown Source)
             at Controller.onFormSubmit(ProposalDetailController.java:178)
             at admin.AdminBaseFormController.onSubmit(AdminBaseFormController.java:130)
             at org.springframework.web.servlet.mvc.SimpleFormController.processFormSubmission(SimpleFormController.java:258)
             at org.springframework.web.servlet.mvc.AbstractFormController.handleRequestInternal(AbstractFormController.java:259)
             at org.springframework.web.servlet.mvc.AbstractController.handleRequest(AbstractController.java:139)
             at org.springframework.web.servlet.mvc.SimpleControllerHandlerAdapter.handle(SimpleControllerHandlerAdapter.java:44)
             at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:717)
             at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:658)
             at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:392)
             at org.springframework.web.servlet.FrameworkServlet.doPost(FrameworkServlet.java:357)
             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.donorschoose.web.filter.ActionFilter.doFilter(ActionFilter.java:112)
             at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
             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:76)
             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.Http11Processor.process(Http11Processor.java:868)
             at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:663)
             at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
             at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
             at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
             at java.lang.Thread.run(Thread.java:595)
            2007-01-03 13:21:09,104 DEBUG [org.springframework.orm.hibernate3.HibernateTransactionManager] - Initiating transaction rollback on commit exception
            org.hibernate.AssertionFailure: collection [org.jbpm.graph.def.Node.leavingTransitions] was not processed by flush()
             at org.hibernate.engine.CollectionEntry.postFlush(CollectionEntry.java:205)
             at org.hibernate.event.def.AbstractFlushingEventListener.postFlush(AbstractFlushingEventListener.java:332)
             at org.hibernate.event.def.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:28)
             at org.hibernate.impl.SessionImpl.flush(SessionImpl.java:985)
             at org.hibernate.impl.SessionImpl.managedFlush(SessionImpl.java:333)
             at org.hibernate.transaction.JDBCTransaction.commit(JDBCTransaction.java:106)
             at org.springframework.orm.hibernate3.HibernateTransactionManager.doCommit(HibernateTransactionManager.java:584)
             at org.springframework.transaction.support.AbstractPlatformTransactionManager.processCommit(AbstractPlatformTransactionManager.java:496)
             at org.springframework.transaction.support.AbstractPlatformTransactionManager.commit(AbstractPlatformTransactionManager.java:469)
             at org.springframework.transaction.interceptor.TransactionAspectSupport.doCommitTransactionAfterReturning(TransactionAspectSupport.java:266)
             at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:106)
             at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:170)
             at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:176)
             at $Proxy6.updateAndAdjustWorkflow(Unknown Source)
             at org.donorschoose.web.control.admin.ProposalDetailController.onFormSubmit(ProposalDetailController.java:178)
             at org.donorschoose.web.control.admin.AdminBaseFormController.onSubmit(AdminBaseFormController.java:130)
             at org.springframework.web.servlet.mvc.SimpleFormController.processFormSubmission(SimpleFormController.java:258)
             at org.springframework.web.servlet.mvc.AbstractFormController.handleRequestInternal(AbstractFormController.java:259)
             at org.springframework.web.servlet.mvc.AbstractController.handleRequest(AbstractController.java:139)
             at org.springframework.web.servlet.mvc.SimpleControllerHandlerAdapter.handle(SimpleControllerHandlerAdapter.java:44)
             at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:717)
             at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:658)
             at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:392)
             at org.springframework.web.servlet.FrameworkServlet.doPost(FrameworkServlet.java:357)
             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.donorschoose.web.filter.ActionFilter.doFilter(ActionFilter.java:112)
             at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
             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:76)
             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.Http11Processor.process(Http11Processor.java:868)
             at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:663)
             at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
             at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
             at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
             at java.lang.Thread.run(Thread.java:595)
            2007-01-03 13:21:09,104 DEBUG [org.springframework.orm.hibernate3.HibernateTransactionManager] - Initiating transaction rollback on commit exception
            org.hibernate.AssertionFailure: collection [org.jbpm.graph.def.Node.leavingTransitions] was not processed by flush()
             at org.hibernate.engine.CollectionEntry.postFlush(CollectionEntry.java:205)
             at org.hibernate.event.def.AbstractFlushingEventListener.postFlush(AbstractFlushingEventListener.java:332)
             at org.hibernate.event.def.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:28)
             at org.hibernate.impl.SessionImpl.flush(SessionImpl.java:985)
             at org.hibernate.impl.SessionImpl.managedFlush(SessionImpl.java:333)
             at org.hibernate.transaction.JDBCTransaction.commit(JDBCTransaction.java:106)
             at org.springframework.orm.hibernate3.HibernateTransactionManager.doCommit(HibernateTransactionManager.java:584)
             at org.springframework.transaction.support.AbstractPlatformTransactionManager.processCommit(AbstractPlatformTransactionManager.java:496)
             at org.springframework.transaction.support.AbstractPlatformTransactionManager.commit(AbstractPlatformTransactionManager.java:469)
             at org.springframework.transaction.interceptor.TransactionAspectSupport.doCommitTransactionAfterReturning(TransactionAspectSupport.java:266)
             at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:106)
             at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:170)
             at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:176)
             at $Proxy6.updateAndAdjustWorkflow(Unknown Source)
             at org.donorschoose.web.control.admin.ProposalDetailController.onFormSubmit(ProposalDetailController.java:178)
             at org.donorschoose.web.control.admin.AdminBaseFormController.onSubmit(AdminBaseFormController.java:130)
             at org.springframework.web.servlet.mvc.SimpleFormController.processFormSubmission(SimpleFormController.java:258)
             at org.springframework.web.servlet.mvc.AbstractFormController.handleRequestInternal(AbstractFormController.java:259)
             at org.springframework.web.servlet.mvc.AbstractController.handleRequest(AbstractController.java:139)
             at org.springframework.web.servlet.mvc.SimpleControllerHandlerAdapter.handle(SimpleControllerHandlerAdapter.java:44)
             at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:717)
             at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:658)
             at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:392)
             at org.springframework.web.servlet.FrameworkServlet.doPost(FrameworkServlet.java:357)
             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.donorschoose.web.filter.ActionFilter.doFilter(ActionFilter.java:112)
             at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
             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:76)
             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.Http11Processor.process(Http11Processor.java:868)
             at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:663)
             at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
             at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
             at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
             at java.lang.Thread.run(Thread.java:595)
            2007-01-03 13:21:09,104 DEBUG [org.springframework.orm.hibernate3.HibernateTransactionManager] - Rolling back Hibernate transaction on Session [org.hibernate.impl.SessionImpl@3e0b62]
            2007-01-03 13:21:09,104 DEBUG [org.springframework.orm.hibernate3.HibernateTransactionManager] - Rolling back Hibernate transaction on Session [org.hibernate.impl.SessionImpl@3e0b62]
            2007-01-03 13:21:09,124 DEBUG [org.hibernate.impl.SessionImpl] - after transaction completion
            2007-01-03 13:21:09,124 DEBUG [org.springframework.orm.hibernate3.HibernateTransactionManager] - Triggering afterCompletion synchronization
            2007-01-03 13:21:09,124 DEBUG [org.springframework.orm.hibernate3.HibernateTransactionManager] - Triggering afterCompletion synchronization
            2007-01-03 13:21:09,124 DEBUG [org.springframework.orm.hibernate3.HibernateTransactionManager] - Not closing pre-bound Hibernate Session [org.hibernate.impl.SessionImpl@3e0b62] after transaction
            2007-01-03 13:21:09,124 DEBUG [org.springframework.orm.hibernate3.HibernateTransactionManager] - Not closing pre-bound Hibernate Session [org.hibernate.impl.SessionImpl@3e0b62] after transaction
            2007-01-03 13:21:09,124 DEBUG [org.hibernate.impl.SessionImpl] - setting flush mode to: NEVER
            2007-01-03 13:21:09,134 ERROR [org.springframework.web.servlet.DispatcherServlet] - Could not complete request
            org.hibernate.AssertionFailure: collection [org.jbpm.graph.def.Node.leavingTransitions] was not processed by flush()
             at org.hibernate.engine.CollectionEntry.postFlush(CollectionEntry.java:205)
             at org.hibernate.event.def.AbstractFlushingEventListener.postFlush(AbstractFlushingEventListener.java:332)
             at org.hibernate.event.def.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:28)
             at org.hibernate.impl.SessionImpl.flush(SessionImpl.java:985)
             at org.hibernate.impl.SessionImpl.managedFlush(SessionImpl.java:333)
             at org.hibernate.transaction.JDBCTransaction.commit(JDBCTransaction.java:106)
             at org.springframework.orm.hibernate3.HibernateTransactionManager.doCommit(HibernateTransactionManager.java:584)
             at org.springframework.transaction.support.AbstractPlatformTransactionManager.processCommit(AbstractPlatformTransactionManager.java:496)
             at org.springframework.transaction.support.AbstractPlatformTransactionManager.commit(AbstractPlatformTransactionManager.java:469)
             at org.springframework.transaction.interceptor.TransactionAspectSupport.doCommitTransactionAfterReturning(TransactionAspectSupport.java:266)
             at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:106)
             at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:170)
             at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:176)
             at $Proxy6.updateAndAdjustWorkflow(Unknown Source)
             at org.donorschoose.web.control.admin.ProposalDetailController.onFormSubmit(ProposalDetailController.java:178)
             at org.donorschoose.web.control.admin.AdminBaseFormController.onSubmit(AdminBaseFormController.java:130)
             at org.springframework.web.servlet.mvc.SimpleFormController.processFormSubmission(SimpleFormController.java:258)
             at org.springframework.web.servlet.mvc.AbstractFormController.handleRequestInternal(AbstractFormController.java:259)
             at org.springframework.web.servlet.mvc.AbstractController.handleRequest(AbstractController.java:139)
             at org.springframework.web.servlet.mvc.SimpleControllerHandlerAdapter.handle(SimpleControllerHandlerAdapter.java:44)
             at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:717)
             at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:658)
             at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:392)
             at org.springframework.web.servlet.FrameworkServlet.doPost(FrameworkServlet.java:357)
             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.donorschoose.web.filter.ActionFilter.doFilter(ActionFilter.java:112)
             at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
             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:76)
             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.Http11Processor.process(Http11Processor.java:868)
             at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:663)
             at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
             at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
             at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
             at java.lang.Thread.run(Thread.java:595)
            2007-01-03 13:21:09,134 DEBUG [org.springframework.orm.hibernate3.support.OpenSessionInViewFilter] - Closing single Hibernate Session in OpenSessionInViewFilter
            2007-01-03 13:21:09,134 DEBUG [org.springframework.orm.hibernate3.support.OpenSessionInViewFilter] - Closing single Hibernate Session in OpenSessionInViewFilter
            2007-01-03 13:21:09,134 DEBUG [org.springframework.orm.hibernate3.SessionFactoryUtils] - Closing Hibernate Session
            2007-01-03 13:21:09,134 DEBUG [org.springframework.orm.hibernate3.SessionFactoryUtils] - Closing Hibernate Session
            2007-01-03 13:21:09,134 DEBUG [org.hibernate.impl.SessionImpl] - closing session
            2007-01-03 13:21:09,134 DEBUG [org.hibernate.impl.SessionImpl] - after transaction completion
            2007-01-03 13:21:09,134 ERROR [org.apache.catalina.core.ContainerBase.[Catalina].[localhost].[/dev].[donorschoose]] - Servlet.service() for servlet donorschoose threw exception
            org.hibernate.AssertionFailure: collection [org.jbpm.graph.def.Node.leavingTransitions] was not processed by flush()
             at org.hibernate.engine.CollectionEntry.postFlush(CollectionEntry.java:205)
             at org.hibernate.event.def.AbstractFlushingEventListener.postFlush(AbstractFlushingEventListener.java:332)
             at org.hibernate.event.def.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:28)
             at org.hibernate.impl.SessionImpl.flush(SessionImpl.java:985)
             at org.hibernate.impl.SessionImpl.managedFlush(SessionImpl.java:333)
             at org.hibernate.transaction.JDBCTransaction.commit(JDBCTransaction.java:106)
             at org.springframework.orm.hibernate3.HibernateTransactionManager.doCommit(HibernateTransactionManager.java:584)
             at org.springframework.transaction.support.AbstractPlatformTransactionManager.processCommit(AbstractPlatformTransactionManager.java:496)
             at org.springframework.transaction.support.AbstractPlatformTransactionManager.commit(AbstractPlatformTransactionManager.java:469)
             at org.springframework.transaction.interceptor.TransactionAspectSupport.doCommitTransactionAfterReturning(TransactionAspectSupport.java:266)
             at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:106)
             at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:170)
             at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:176)
             at $Proxy6.updateAndAdjustWorkflow(Unknown Source)
             at org.donorschoose.web.control.admin.ProposalDetailController.onFormSubmit(ProposalDetailController.java:178)
             at org.donorschoose.web.control.admin.AdminBaseFormController.onSubmit(AdminBaseFormController.java:130)
             at org.springframework.web.servlet.mvc.SimpleFormController.processFormSubmission(SimpleFormController.java:258)
             at org.springframework.web.servlet.mvc.AbstractFormController.handleRequestInternal(AbstractFormController.java:259)
             at org.springframework.web.servlet.mvc.AbstractController.handleRequest(AbstractController.java:139)
             at org.springframework.web.servlet.mvc.SimpleControllerHandlerAdapter.handle(SimpleControllerHandlerAdapter.java:44)
             at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:717)
             at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:658)
             at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:392)
             at org.springframework.web.servlet.FrameworkServlet.doPost(FrameworkServlet.java:357)
             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.donorschoose.web.filter.ActionFilter.doFilter(ActionFilter.java:112)
             at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
             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:76)
             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.Http11Processor.process(Http11Processor.java:868)
             at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:663)
             at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
             at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
             at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
             at java.lang.Thread.run(Thread.java:595)
            2007-01-03 13:25:43,198 INFO [org.apache.catalina.core.ContainerBase.[Catalina].[localhost].[/dev]] - Closing WebApplicationContext of Spring FrameworkServlet 'donorschoose'


            • 3. Re: org.hibernate.AssertionFailure: collection [org.jbpm.gra
              Syed Arshad Newbie

              I found this

              timers are updated only with a saveProcessInstance or a signal.
              from
              http://www.jboss.com/index.html?module=bb&op=viewtopic&t=69040

              so, i tried jbpmContext.save(processInstance) to save the updated timers but this is throwing the same exception except the assertion error we are getting it for [org.jbpm.graph.def.Node.arrivingTransitions]

              2007-01-03 20:26:57,502 DEBUG [org.springframework.orm.hibernate3.HibernateTransactionManager] - Committing Hibernate transaction on Session [org.hibernate.impl.SessionImpl@b62081]
              2007-01-03 20:26:57,502 DEBUG [org.hibernate.impl.SessionImpl] - automatically flushing session
              2007-01-03 20:26:57,512 DEBUG [org.hibernate.impl.SessionImpl] - initializing proxy: [org.jbpm.graph.node.State#3314]
              2007-01-03 20:26:57,623 ERROR [org.hibernate.AssertionFailure] - an assertion failure occured (this may indicate a bug in Hibernate, but is more likely due to unsafe use of the session)
              org.hibernate.AssertionFailure: collection [org.jbpm.graph.def.Node.arrivingTransitions] was not processed by flush()
               at org.hibernate.engine.CollectionEntry.postFlush(CollectionEntry.java:205)
               at org.hibernate.event.def.AbstractFlushingEventListener.postFlush(AbstractFlushingEventListener.java:332)
               at org.hibernate.event.def.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:28)
               at org.hibernate.impl.SessionImpl.flush(SessionImpl.java:985)
               at org.hibernate.impl.SessionImpl.managedFlush(SessionImpl.java:333)
               at org.hibernate.transaction.JDBCTransaction.commit(JDBCTransaction.java:106)
               at org.springframework.orm.hibernate3.HibernateTransactionManager.doCommit(HibernateTransactionManager.java:584)
               at org.springframework.transaction.support.AbstractPlatformTransactionManager.processCommit(AbstractPlatformTransactionManager.java:496)
               at org.springframework.transaction.support.AbstractPlatformTransactionManager.commit(AbstractPlatformTransactionManager.java:469)
               at org.springframework.transaction.interceptor.TransactionAspectSupport.doCommitTransactionAfterReturning(TransactionAspectSupport.java:266)
               at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:106)
               at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:170)
               at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:176)
               at $Proxy6.updateAndAdjustWorkflow(Unknown Source)
               at org.donorschoose.web.control.admin.ProposalDetailController.onFormSubmit(ProposalDetailController.java:178)
               at org.donorschoose.web.control.admin.AdminBaseFormController.onSubmit(AdminBaseFormController.java:130)
               at org.springframework.web.servlet.mvc.SimpleFormController.processFormSubmission(SimpleFormController.java:258)
               at org.springframework.web.servlet.mvc.AbstractFormController.handleRequestInternal(AbstractFormController.java:259)
               at org.springframework.web.servlet.mvc.AbstractController.handleRequest(AbstractController.java:139)
               at org.springframework.web.servlet.mvc.SimpleControllerHandlerAdapter.handle(SimpleControllerHandlerAdapter.java:44)
               at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:717)
               at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:658)
               at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:392)
               at org.springframework.web.servlet.FrameworkServlet.doPost(FrameworkServlet.java:357)
               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.donorschoose.web.filter.ActionFilter.doFilter(ActionFilter.java:112)
               at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
               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:76)
               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.Http11Processor.process(Http11Processor.java:868)
               at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:663)
               at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
               at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
               at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
               at java.lang.Thread.run(Thread.java:595)
              2007-01-03 20:26:57,773 DEBUG [org.springframework.orm.hibernate3.HibernateTransactionManager] - Initiating transaction rollback on commit exception
              org.hibernate.AssertionFailure: collection [org.jbpm.graph.def.Node.arrivingTransitions] was not processed by flush()
               at org.hibernate.engine.CollectionEntry.postFlush(CollectionEntry.java:205)
               at org.hibernate.event.def.AbstractFlushingEventListener.postFlush(AbstractFlushingEventListener.java:332)
               at org.hibernate.event.def.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:28)
               at org.hibernate.impl.SessionImpl.flush(SessionImpl.java:985)
               at org.hibernate.impl.SessionImpl.managedFlush(SessionImpl.java:333)
               at org.hibernate.transaction.JDBCTransaction.commit(JDBCTransaction.java:106)
               at org.springframework.orm.hibernate3.HibernateTransactionManager.doCommit(HibernateTransactionManager.java:584)
               at org.springframework.transaction.support.AbstractPlatformTransactionManager.processCommit(AbstractPlatformTransactionManager.java:496)
               at org.springframework.transaction.support.AbstractPlatformTransactionManager.commit(AbstractPlatformTransactionManager.java:469)
               at org.springframework.transaction.interceptor.TransactionAspectSupport.doCommitTransactionAfterReturning(TransactionAspectSupport.java:266)
               at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:106)
               at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:170)
               at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:176)
               at $Proxy6.updateAndAdjustWorkflow(Unknown Source)
               at org.donorschoose.web.control.admin.ProposalDetailController.onFormSubmit(ProposalDetailController.java:178)
               at org.donorschoose.web.control.admin.AdminBaseFormController.onSubmit(AdminBaseFormController.java:130)
               at org.springframework.web.servlet.mvc.SimpleFormController.processFormSubmission(SimpleFormController.java:258)
               at org.springframework.web.servlet.mvc.AbstractFormController.handleRequestInternal(AbstractFormController.java:259)
               at org.springframework.web.servlet.mvc.AbstractController.handleRequest(AbstractController.java:139)
               at org.springframework.web.servlet.mvc.SimpleControllerHandlerAdapter.handle(SimpleControllerHandlerAdapter.java:44)
               at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:717)
               at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:658)
               at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:392)
               at org.springframework.web.servlet.FrameworkServlet.doPost(FrameworkServlet.java:357)
               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.donorschoose.web.filter.ActionFilter.doFilter(ActionFilter.java:112)
               at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
               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:76)
               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.Http11Processor.process(Http11Processor.java:868)
               at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:663)
               at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
               at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
               at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
               at java.lang.Thread.run(Thread.java:595)
              2007-01-03 20:26:57,773 DEBUG [org.springframework.orm.hibernate3.HibernateTransactionManager] - Initiating transaction rollback on commit exception
              org.hibernate.AssertionFailure: collection [org.jbpm.graph.def.Node.arrivingTransitions] was not processed by flush()
               at org.hibernate.engine.CollectionEntry.postFlush(CollectionEntry.java:205)
               at org.hibernate.event.def.AbstractFlushingEventListener.postFlush(AbstractFlushingEventListener.java:332)
               at org.hibernate.event.def.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:28)
               at org.hibernate.impl.SessionImpl.flush(SessionImpl.java:985)
               at org.hibernate.impl.SessionImpl.managedFlush(SessionImpl.java:333)
               at org.hibernate.transaction.JDBCTransaction.commit(JDBCTransaction.java:106)
               at org.springframework.orm.hibernate3.HibernateTransactionManager.doCommit(HibernateTransactionManager.java:584)
               at org.springframework.transaction.support.AbstractPlatformTransactionManager.processCommit(AbstractPlatformTransactionManager.java:496)
               at org.springframework.transaction.support.AbstractPlatformTransactionManager.commit(AbstractPlatformTransactionManager.java:469)
               at org.springframework.transaction.interceptor.TransactionAspectSupport.doCommitTransactionAfterReturning(TransactionAspectSupport.java:266)
               at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:106)
               at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:170)
               at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:176)
               at $Proxy6.updateAndAdjustWorkflow(Unknown Source)
               at org.donorschoose.web.control.admin.ProposalDetailController.onFormSubmit(ProposalDetailController.java:178)
               at org.donorschoose.web.control.admin.AdminBaseFormController.onSubmit(AdminBaseFormController.java:130)
               at org.springframework.web.servlet.mvc.SimpleFormController.processFormSubmission(SimpleFormController.java:258)
               at org.springframework.web.servlet.mvc.AbstractFormController.handleRequestInternal(AbstractFormController.java:259)
               at org.springframework.web.servlet.mvc.AbstractController.handleRequest(AbstractController.java:139)
               at org.springframework.web.servlet.mvc.SimpleControllerHandlerAdapter.handle(SimpleControllerHandlerAdapter.java:44)
               at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:717)
               at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:658)
               at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:392)
               at org.springframework.web.servlet.FrameworkServlet.doPost(FrameworkServlet.java:357)
               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.donorschoose.web.filter.ActionFilter.doFilter(ActionFilter.java:112)
               at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
               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:76)
               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.Http11Processor.process(Http11Processor.java:868)
               at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:663)
               at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
               at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
               at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
               at java.lang.Thread.run(Thread.java:595)
              2007-01-03 20:26:57,783 DEBUG [org.springframework.orm.hibernate3.HibernateTransactionManager] - Rolling back Hibernate transaction on Session [org.hibernate.impl.SessionImpl@b62081]
              2007-01-03 20:26:57,783 DEBUG [org.springframework.orm.hibernate3.HibernateTransactionManager] - Rolling back Hibernate transaction on Session [org.hibernate.impl.SessionImpl@b62081]
              2007-01-03 20:26:57,883 DEBUG [org.hibernate.impl.SessionImpl] - after transaction completion
              2007-01-03 20:26:57,883 DEBUG [org.springframework.orm.hibernate3.HibernateTransactionManager] - Triggering afterCompletion synchronization
              2007-01-03 20:26:57,883 DEBUG [org.springframework.orm.hibernate3.HibernateTransactionManager] - Triggering afterCompletion synchronization
              2007-01-03 20:26:57,883 DEBUG [org.springframework.orm.hibernate3.HibernateTransactionManager] - Not closing pre-bound Hibernate Session [org.hibernate.impl.SessionImpl@b62081] after transaction
              2007-01-03 20:26:57,883 DEBUG [org.springframework.orm.hibernate3.HibernateTransactionManager] - Not closing pre-bound Hibernate Session [org.hibernate.impl.SessionImpl@b62081] after transaction
              2007-01-03 20:26:57,883 DEBUG [org.hibernate.impl.SessionImpl] - setting flush mode to: NEVER
              2007-01-03 20:26:57,883 ERROR [org.springframework.web.servlet.DispatcherServlet] - Could not complete request
              org.hibernate.AssertionFailure: collection [org.jbpm.graph.def.Node.arrivingTransitions] was not processed by flush()
               at org.hibernate.engine.CollectionEntry.postFlush(CollectionEntry.java:205)
               at org.hibernate.event.def.AbstractFlushingEventListener.postFlush(AbstractFlushingEventListener.java:332)
               at org.hibernate.event.def.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:28)
               at org.hibernate.impl.SessionImpl.flush(SessionImpl.java:985)
               at org.hibernate.impl.SessionImpl.managedFlush(SessionImpl.java:333)
               at org.hibernate.transaction.JDBCTransaction.commit(JDBCTransaction.java:106)
               at org.springframework.orm.hibernate3.HibernateTransactionManager.doCommit(HibernateTransactionManager.java:584)
               at org.springframework.transaction.support.AbstractPlatformTransactionManager.processCommit(AbstractPlatformTransactionManager.java:496)
               at org.springframework.transaction.support.AbstractPlatformTransactionManager.commit(AbstractPlatformTransactionManager.java:469)
               at org.springframework.transaction.interceptor.TransactionAspectSupport.doCommitTransactionAfterReturning(TransactionAspectSupport.java:266)
               at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:106)
               at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:170)
               at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:176)
               at $Proxy6.updateAndAdjustWorkflow(Unknown Source)
               at org.donorschoose.web.control.admin.ProposalDetailController.onFormSubmit(ProposalDetailController.java:178)
               at org.donorschoose.web.control.admin.AdminBaseFormController.onSubmit(AdminBaseFormController.java:130)
               at org.springframework.web.servlet.mvc.SimpleFormController.processFormSubmission(SimpleFormController.java:258)
               at org.springframework.web.servlet.mvc.AbstractFormController.handleRequestInternal(AbstractFormController.java:259)
               at org.springframework.web.servlet.mvc.AbstractController.handleRequest(AbstractController.java:139)
               at org.springframework.web.servlet.mvc.SimpleControllerHandlerAdapter.handle(SimpleControllerHandlerAdapter.java:44)
               at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:717)
               at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:658)
               at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:392)
               at org.springframework.web.servlet.FrameworkServlet.doPost(FrameworkServlet.java:357)
               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.donorschoose.web.filter.ActionFilter.doFilter(ActionFilter.java:112)
               at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
               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:76)
               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.Http11Processor.process(Http11Processor.java:868)
               at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:663)
               at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
               at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
               at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
               at java.lang.Thread.run(Thread.java:595)
              2007-01-03 20:26:57,893 DEBUG [org.springframework.orm.hibernate3.support.OpenSessionInViewFilter] - Closing single Hibernate Session in OpenSessionInViewFilter
              2007-01-03 20:26:57,893 DEBUG [org.springframework.orm.hibernate3.support.OpenSessionInViewFilter] - Closing single Hibernate Session in OpenSessionInViewFilter
              2007-01-03 20:26:57,893 DEBUG [org.springframework.orm.hibernate3.SessionFactoryUtils] - Closing Hibernate Session
              2007-01-03 20:26:57,893 DEBUG [org.springframework.orm.hibernate3.SessionFactoryUtils] - Closing Hibernate Session
              2007-01-03 20:26:57,893 DEBUG [org.hibernate.impl.SessionImpl] - closing session
              2007-01-03 20:26:57,893 DEBUG [org.hibernate.impl.SessionImpl] - after transaction completion
              2007-01-03 20:26:57,893 ERROR [org.apache.catalina.core.ContainerBase.[Catalina].[localhost].[/dev].[donorschoose]] - Servlet.service() for servlet donorschoose threw exception
              org.hibernate.AssertionFailure: collection [org.jbpm.graph.def.Node.arrivingTransitions] was not processed by flush()
               at org.hibernate.engine.CollectionEntry.postFlush(CollectionEntry.java:205)
               at org.hibernate.event.def.AbstractFlushingEventListener.postFlush(AbstractFlushingEventListener.java:332)
               at org.hibernate.event.def.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:28)
               at org.hibernate.impl.SessionImpl.flush(SessionImpl.java:985)
               at org.hibernate.impl.SessionImpl.managedFlush(SessionImpl.java:333)
               at org.hibernate.transaction.JDBCTransaction.commit(JDBCTransaction.java:106)
               at org.springframework.orm.hibernate3.HibernateTransactionManager.doCommit(HibernateTransactionManager.java:584)
               at org.springframework.transaction.support.AbstractPlatformTransactionManager.processCommit(AbstractPlatformTransactionManager.java:496)
               at org.springframework.transaction.support.AbstractPlatformTransactionManager.commit(AbstractPlatformTransactionManager.java:469)
               at org.springframework.transaction.interceptor.TransactionAspectSupport.doCommitTransactionAfterReturning(TransactionAspectSupport.java:266)
               at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:106)
               at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:170)
               at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:176)
               at $Proxy6.updateAndAdjustWorkflow(Unknown Source)
               at org.donorschoose.web.control.admin.ProposalDetailController.onFormSubmit(ProposalDetailController.java:178)
               at org.donorschoose.web.control.admin.AdminBaseFormController.onSubmit(AdminBaseFormController.java:130)
               at org.springframework.web.servlet.mvc.SimpleFormController.processFormSubmission(SimpleFormController.java:258)
               at org.springframework.web.servlet.mvc.AbstractFormController.handleRequestInternal(AbstractFormController.java:259)
               at org.springframework.web.servlet.mvc.AbstractController.handleRequest(AbstractController.java:139)
               at org.springframework.web.servlet.mvc.SimpleControllerHandlerAdapter.handle(SimpleControllerHandlerAdapter.java:44)
               at org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:717)
               at org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:658)
               at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:392)
               at org.springframework.web.servlet.FrameworkServlet.doPost(FrameworkServlet.java:357)
               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.donorschoose.web.filter.ActionFilter.doFilter(ActionFilter.java:112)
               at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
               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:76)
               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.Http11Processor.process(Http11Processor.java:868)
               at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:663)
               at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
               at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
               at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
               at java.lang.Thread.run(Thread.java:595)



              • 4. Timer due date update issue!
                Syed Arshad Newbie

                Hello guys, i am not sure it is a bug or something wrong with the way we are using. I would appreciate if you could help us to resolve this.

                • 5. Re: org.hibernate.AssertionFailure: collection [org.jbpm.gra
                  Koen Aers Master

                  This looks like a Spring/jBPM combination issue. I never did this, so I cannot comment in detail. But you should certainly make sure that jBPM is using the same hibernate session and the same transaction as the rest of your application.

                  Regards,
                  Koen

                  • 6. Re: org.hibernate.AssertionFailure: collection [org.jbpm.gra
                    Jesper Berglund Newbie

                    I have the same issue and I am using jBPM 3.1.3, hibernate 3.2.0GA on a JBOSS 4.0.5GA.
                    I retrieve the Timer from the SchedulerSession and set the new calculated duedate and I am unable to save the changes made.

                    This is the exception trace:

                    11:39:51,514 ERROR [AssertionFailure] an assertion failure occured (this may indicate a bug in Hibernate, but is more likely due to unsafe use of the session)
                    org.hibernate.AssertionFailure: collection [org.jbpm.graph.def.Node.exceptionHandlers] was not processed by flush()
                     at org.hibernate.engine.CollectionEntry.postFlush(CollectionEntry.java:205)
                     at org.hibernate.event.def.AbstractFlushingEventListener.postFlush(AbstractFlushingEventListener.java:333)
                     at org.hibernate.event.def.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:28)
                     at org.hibernate.impl.SessionImpl.flush(SessionImpl.java:1000)
                     at se.sqs.production.workflow.GetStateAction.execute(GetStateAction.java:101)
                     at org.jbpm.graph.def.Action.execute(Action.java:123)
                     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:597)
                     at org.hibernate.proxy.pojo.cglib.CGLIBLazyInitializer.invoke(CGLIBLazyInitializer.java:185)
                     at org.jbpm.graph.def.Action$$EnhancerByCGLIB$$d88de83f.execute(<generated>)
                     at org.jbpm.graph.def.Node.execute(Node.java:328)
                     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:597)
                     at org.hibernate.proxy.pojo.cglib.CGLIBLazyInitializer.invoke(CGLIBLazyInitializer.java:185)
                     at org.jbpm.graph.def.Node$$EnhancerByCGLIB$$df23eee3.execute(<generated>)
                     at org.jbpm.command.ExecuteNodeCommand.execute(ExecuteNodeCommand.java:57)
                     at org.jbpm.msg.command.CommandExecutorThread.executeCommand(CommandExecutorThread.java:135)
                     at org.jbpm.msg.command.CommandExecutorThread.run(CommandExecutorThread.java:83)
                    11:39:51,655 ERROR [GetStateAction] collection [org.jbpm.graph.def.Node.exceptionHandlers] was not processed by flush()
                    org.hibernate.AssertionFailure: collection [org.jbpm.graph.def.Node.exceptionHandlers] was not processed by flush()
                     at org.hibernate.engine.CollectionEntry.postFlush(CollectionEntry.java:205)
                     at org.hibernate.event.def.AbstractFlushingEventListener.postFlush(AbstractFlushingEventListener.java:333)
                     at org.hibernate.event.def.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:28)
                     at org.hibernate.impl.SessionImpl.flush(SessionImpl.java:1000)
                     at se.sqs.production.workflow.GetStateAction.execute(GetStateAction.java:101)
                     at org.jbpm.graph.def.Action.execute(Action.java:123)
                     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:597)
                     at org.hibernate.proxy.pojo.cglib.CGLIBLazyInitializer.invoke(CGLIBLazyInitializer.java:185)
                     at org.jbpm.graph.def.Action$$EnhancerByCGLIB$$d88de83f.execute(<generated>)
                     at org.jbpm.graph.def.Node.execute(Node.java:328)
                     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:597)
                     at org.hibernate.proxy.pojo.cglib.CGLIBLazyInitializer.invoke(CGLIBLazyInitializer.java:185)
                     at org.jbpm.graph.def.Node$$EnhancerByCGLIB$$df23eee3.execute(<generated>)
                     at org.jbpm.command.ExecuteNodeCommand.execute(ExecuteNodeCommand.java:57)
                     at org.jbpm.msg.command.CommandExecutorThread.executeCommand(CommandExecutorThread.java:135)
                     at org.jbpm.msg.command.CommandExecutorThread.run(CommandExecutorThread.java:83)
                    


                    I have tried to save the timer through the SchedulerSession. I have also tried to save the ProcessInstance with the same result.

                    Has anyone resolved this issue ?

                    My business logic fails because of this "bug" :-(.

                    /Jesper

                    • 7. Re: org.hibernate.AssertionFailure: collection [org.jbpm.gra
                      Jesper Berglund Newbie

                      Solved it, I did not use the current session, I created a new one.

                      The new session had no qlue what the current got.

                      /Jesper

                      • 8. Re: org.hibernate.AssertionFailure: collection [org.jbpm.gra
                        Deepika Rashmi Newbie

                        Hi,

                        If you could please let us know how you had fixed the code then it would be of great help.

                        Thanks in advance

                        • 9. Re: org.hibernate.AssertionFailure: collection [org.jbpm.gra
                          Anurag Paliwal Newbie

                          Hi jasper,

                          Are you using spring module for jBPM?

                          Code pasted in very first post is using jbpmContext to get the scheduler session. I would imagine that jbpmCOntext would be using the same hibernate session.

                          Any comment???