2 Replies Latest reply on Feb 28, 2008 4:15 AM by bungrudi

    New process instance always get persisted

    bungrudi

      Dear all,

      When in a persistence context, creating a process instance using JbpmContext.createNewProcessInstance(String procDefName) always end up with the newly created instance persisted in the database.
      I think this should not be the case, since there is JbpmContext.createNewProcessInstanceForUpdate(String procDefName).
      The latter should be creating an instance that is persisted upon creation, while the first should create a transient task instance that should be manually persisted.
      This auto persisting behaviour is coded into one of only two ProcessInstance constructor.

      I'm using 3.1.4 and don't know if this have changed in later version, nor is this an intended behaviour.

      Should I file a bug?

      regards,

      Rudi

        • 1. Re: New process instance always get persisted
          kukeltje

           

          I'm using 3.1.4 and don't know if this have changed in later version, nor is this an intended behaviour.


          This behaviour will not be changed in 3.1 or 3.2 (or the 3.x branch at all, but I'm not sure nor 'authorized' to state that).

          3.1 is in maintanance 'mode' and such 'fundamental' changes will not be made. If the same behaviour exists in 3.2 can be found out by trying or looking at the code. If this behaviour is changed. Lots of people probably have to change their software, so filing it as a 'bug' will not be ok. Filing at as a feature/change request might, but I think only for 4.0

          I'm not sure what 4.0 will bring anyway so it might be worth to check the source of the PVM and comment on that.

          • 2. Re: New process instance always get persisted
            bungrudi

            I'll propose a feature, a factory method in JbpmContext and/or a new constructor in ProcessInstance that produces transient ProcessInstance.