1 Reply Latest reply on Jan 6, 2007 6:41 AM by Koen Aers

    Exception with Mysql during deployment of processdefinition

    anu123suya Newbie

      Hi,
      I could deploy a processdefinition in default hypersonic db. but when i try to deploy it in Mysql getting the following exception. have added users in the users table manually.




      code used for deployment is



      JbpmConfiguration jbpmConfig = JbpmConfiguration.getInstance();
      JbpmContext jbpmContext = jbpmConfig.createJbpmContext();
      ProcessDefinition processDefinition = ProcessDefinition.parseXmlResource("META-INF/processdefinition.xml");
      jbpmContext.deployProcessDefinition(processDefinition);

      Can anyone let me know if i am missing something??


      Thanks in advance


      processdefinition.xml is

      <process-definition
       xmlns="urn:jbpm.org:jpdl-3.1" name="LeaveApproval">
      
       <swimlane name="Applier">
       <assignment expression="user(Ana)"></assignment>
       </swimlane>
       <swimlane name="Approver">
       <assignment expression="user(Bask)"></assignment>
       </swimlane>
       <start-state name="ApplyLeave">
       <task name="ApplyLeave" swimlane="Applicant">
       <controller>
       <variable name="Start Date" access="read,write,required"></variable>
       <variable name="Duration" access="read,write,required"></variable>
       <variable name="Reason For Leave"></variable>
       </controller>
       </task>
       <transition name="" to="EvaluateLeave"></transition>
       </start-state>
       <task-node name="EvaluateLeave">
       <task name="EvaluateLeave" swimlane="Approver">
       <controller>
       <variable name="Start Date" access="read"></variable>
       <variable name="Duration" access="read"></variable>
       <variable name="Reason" access="read"></variable>
       <variable name="Comments"></variable>
       </controller>
       </task>
       <transition name="Approve/disapprove" to="End"></transition>
       <transition name="Provide More Info" to="MoreInfoNeeded"></transition>
       </task-node>
       <task-node name="MoreInfoNeeded">
       <task name="Edit Leave Info" swimlane="Applicant">
       <controller>
       <variable name="Start Date"></variable>
       <variable name="Duration"></variable>
       <variable name="Reason"></variable>
       <variable name="Comment" access="read"></variable>
       </controller>
       </task>
       <transition name="" to="EvaluateLeave"></transition>
       </task-node>
       <end-state name="End"></end-state>
      </process-definition>
      
      
      
      




      Stack trace is

      18:51:46,325 WARN [JpdlXmlReader] process xml warning: task references unknown
      swimlane 'Applicant':<task xmlns="urn:jbpm.org:jpdl-3.1" name="ApplyLeave" swiml
      ane="Applicant" blocking="false" signalling="true" priority="normal">
      <controller config-type="field">





      18:51:46,340 WARN [JpdlXmlReader] process xml warning: task references unknown
      swimlane 'Applicant':
      <controller config-type="field">






      18:52:37,903 WARN [JDBCExceptionReporter] SQL Error: 1205, SQLState: 41000
      18:52:37,903 ERROR [JDBCExceptionReporter] Lock wait timeout exceeded; try resta
      rting transaction
      18:52:37,903 ERROR [[jsp]] Servlet.service() for servlet jsp threw exception
      org.hibernate.exception.GenericJDBCException: could not insert: [org.jbpm.graph.
      def.ProcessDefinition]
      at org.hibernate.exception.SQLStateConverter.handledNonSpecificException
      (SQLStateConverter.java:91)
      at org.hibernate.exception.SQLStateConverter.convert(SQLStateConverter.j
      ava:79)
      at org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelp
      er.java:43)
      at org.hibernate.persister.entity.AbstractEntityPersister.insert(Abstrac
      tEntityPersister.java:1985)
      at org.hibernate.persister.entity.AbstractEntityPersister.insert(Abstrac
      tEntityPersister.java:2404)
      at org.hibernate.action.EntityIdentityInsertAction.execute(EntityIdentit
      yInsertAction.java:37)
      at org.hibernate.engine.ActionQueue.execute(ActionQueue.java:243)
      at org.hibernate.event.def.AbstractSaveEventListener.performSaveOrReplic
      ate(AbstractSaveEventListener.java:269)
      at org.hibernate.event.def.AbstractSaveEventListener.performSave(Abstrac
      tSaveEventListener.java:167)
      at org.hibernate.event.def.AbstractSaveEventListener.saveWithGeneratedId
      (AbstractSaveEventListener.java:101)
      at org.hibernate.event.def.DefaultSaveOrUpdateEventListener.saveWithGene
      ratedOrRequestedId(DefaultSaveOrUpdateEventListener.java:186)
      at org.hibernate.event.def.DefaultSaveEventListener.saveWithGeneratedOrR
      equestedId(DefaultSaveEventListener.java:33)
      at org.hibernate.event.def.DefaultSaveOrUpdateEventListener.entityIsTran
      sient(DefaultSaveOrUpdateEventListener.java:175)
      at org.hibernate.event.def.DefaultSaveEventListener.performSaveOrUpdate(
      DefaultSaveEventListener.java:27)
      at org.hibernate.event.def.DefaultSaveOrUpdateEventListener.onSaveOrUpda
      te(DefaultSaveOrUpdateEventListener.java:70)
      at org.hibernate.impl.SessionImpl.fireSave(SessionImpl.java:524)
      at org.hibernate.impl.SessionImpl.save(SessionImpl.java:514)
      at org.hibernate.impl.SessionImpl.save(SessionImpl.java:510)
      at org.jbpm.db.GraphSession.deployProcessDefinition(GraphSession.java:77
      )
      at org.jbpm.JbpmContext.deployProcessDefinition(JbpmContext.java:173)
      at org.apache.jsp.Testdeploy_jsp._jspService(Testdeploy_jsp.java:51)
      at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97)
      at javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
      at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper
      .java:332)
      at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:3
      14)
      at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
      at javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Appl
      icationFilterChain.java:252)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationF
      ilterChain.java:173)
      at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFi
      lter.java:96)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Appl
      icationFilterChain.java:202)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationF
      ilterChain.java:173)
      at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperV
      alve.java:213)<?xml version="1.0" encoding="UTF-8"?>