2 Replies Latest reply on Dec 22, 2005 9:51 PM by Elmo

    What does a previous actorid mean

    Elmo Novice

      Hello,

      I was testing with the task-assign event and wanted to see the ff (from the manual)


      task-assign is fired when a task instance is being assigned. Note that in actions that are executed on this event, you can access the previous actor with executionContext.getTaskInstance().getPreviousActorId();


      Based on this, my understanding is the actorid previously assigned for this task instance before re-assigning to another actor. When I test the
      executionContext.getTaskInstance().getPreviousActorId() it returns null. Maybe I didn't get it. What does a previous actor id mean in relation to a task instance?

      Regards,

      Elmo

        • 1. Re: What does a previous actorid mean
          Alejandro Guizar Master

          You're using jBPM 3.0.x, right? There is a bug in the TaskInstance.setActorId() method: it fires the task-assign event before setting the previousActorId field. This has been fixed in 3.1. It seems simple to backport, so let us know if you cannot or do not want to migrate to 3.1.

          • 2. Re: What does a previous actorid mean
            Elmo Novice

            Hi Alex,

            Yes I am using 3.0.2. I have not yet moved to 3.1. I have also tested the process-state, i.e. the process-state name must match the sub-process name in order for it to work. Simply setting sub-process state name does not work. Are these issues already fixed in 3.1? cause if it is, i think i will consider migrating.

            P.S. There is a also little typo error in this version. In the JBPM_TASKINSTANCE table, the field there is SWIMLANINSTANCE_, it should have been SWIMLANEINSTANCE_. It took me a while to figure it out in my SQL queries. FYI.

            Regards,

            Elmo