5 Replies Latest reply on Dec 22, 2010 3:16 PM by mwohlf

    jBPM 4.2 to 4.4 - Upgrade Issue

    justin.l

      Hi Experts,

       

      We were using jBPM 4.2 for our clients and recently upgraded to jBPM 4.4.
      With 4.4, the users are getting the below unique constraint error when they try to save the workflow.

       

      ORA-00001: unique constraint (JBPM4PK_DEPLOYMENT_1) violated.

       

      To upgrade to 4.4, is it required to delete all the workflow definitions which are created with version 4.2?


      Can anyone please guide me in resolving this issue?


      Thanks for your valuable reply.

        • 1. Re: jBPM 4.2 to 4.4 - Upgrade Issue
          mwohlf

          Hi Justin,

          I haven't seen such a contraint, are you sure this is from jBPM4.4?

          You don't need to delete your workflow definition when upgrading the engine.

          • 2. Re: jBPM 4.2 to 4.4 - Upgrade Issue
            justin.l

            Hi Michael,

             

            Sorry for the confusion. I added the constraint name to the coulmn DBID_ in table JBPM4_DEPLOYMENT.

            I guess the 4.4 engine is generating the db id which is already exists in this coulmn? or did I miss any upgrade steps?

             

            Please guide.

            Thanks!

             

             

            • 3. Re: jBPM 4.2 to 4.4 - Upgrade Issue
              mwohlf

              the DBID_ should be unique so the constraint violation is indeed a problem, the engine should generate the DBID_ the config part in

              jbpm4.cfg.xml looks like this:

               

              [...]
              <object class="org.jbpm.pvm.internal.id.DatabaseDbidGenerator">
                    <field name="targetExceptionClass"><class class-name="org.hibernate.StaleStateException" /></field>
                    <field name="commandService"><ref object="newTxRequiredCommandService" /></field>
              </object>
              <object class="org.jbpm.pvm.internal.id.DatabaseIdComposer" init="eager" />
              [...]
              

               

              and I think you are right the problem could be the DbidGenerator generating the same Dbid twice,

              as far as i remember i have seen in the source somewhere that it is supposed to find the highest Dbid at bootup time, but not sure about that....

              • 4. Re: jBPM 4.2 to 4.4 - Upgrade Issue
                justin.l

                I dont see this statement in jbpm.default.cfg.xml

                <field name="targetExceptionClass"><class class-name="org.hibernate.StaleStateException" /></field>.

                 

                So any ideas how to fix thi issue?

                • 5. Re: jBPM 4.2 to 4.4 - Upgrade Issue
                  mwohlf

                  maybe turn on logging for org.jbpm.pvm.internal.id.DatabaseDbidGenerator to figure out what is going on ?