4 Replies Latest reply on Jan 7, 2007 5:54 AM by nib

    Strange .leaveNode() Behaviour

    nib

      Hi,
      if have the following problem:

      I have a Node node which has two leaving transitions. In the actionHandler (event: Node-Enter) I choose the "right" transition. It works fine and it executes two tasknodes (fork/join) and they are assigend to a user.
      But then something goes wrong: The Node node mentioned above chooses the "left" transition (without any interaction) and executes the following Node node. Why does that happen?
      Illustration:

      Node node
      / \
      / (left) \ (right)
      Node node Node fork
      / \
      / \
      Node Task Node task
      \ /
      \ /
      Node join

        • 1. Re: Strange .leaveNode() Behaviour
          nib

           

          Node node
           / \
           / (left) \ (right)
           Node node Node fork
           / \
           / \
           Node Task Node task
           \ /
           \ /
           Node join


          That looks nicer ;-)

          • 2. Re: Strange .leaveNode() Behaviour
            nib

            Addition:

            When Entering the first Node node I get the following:
            DEBUG [Token] token[8] is locked by token[8]

            After executing both Node tasks I get:
            DEBUG [Token] token[8] is unlocked by token[8]


            • 3. Re: Strange .leaveNode() Behaviour
              kukeltje

              please post a unittest (actionhandler, process etc..etc.) ... we have no idea what you do in the actionhandler and cannot guess

              • 4. Re: Strange .leaveNode() Behaviour
                nib

                Solved that one. In Actions within an event you can't propagate execution (.leaveNode("transition")). So I defined an action handler directly on the node and it works. But unfortunately the forms created with the designer do not work (jBPM 3.2 alpha 2 and beta 1).