2 Replies Latest reply on Dec 7, 2012 2:56 AM by oli83

    jBPM5 Error handling

    oli83

      Hi,

       

      I've looked about error handling in jbpm5 and i still don't get how it works (solutions were like making a sub process etc..).

       

      In jbpm4 when there were exceptions in nodes, process instances went back to the node before.

      It's not the case anymore in jBPM 5 and the process still go forward.

       

      My question is : How can I properly handle exceptions like Script task, Email and so on ?

      Can I go back to the previous node (task) like jbpm4 ?

       

      Thanks in advance

        • 1. Re: jBPM5 Error handling
          swiderski.maciej

          I believe that error handling in both versions (4.4 and 5.x) is exactly the same, if exception is thrown then transaction is rolled back and process remains in the last known wait state. It could be the previous node but it does not have to be as it depends when the last safe state was. Important is that the exception must not be caught so it reaches engine so it can react on it and rollback transaction.

           

          If you see different behavior could you please provide test case that illustrates this?

           

          HTH

          • 2. Re: jBPM5 Error handling
            oli83

            Hi,

             

            Thanks for your answer.

             

            Actually a simple process with a Human task followed by a Script task with a java Exception illustrate this