1 Reply Latest reply on Dec 17, 2009 11:51 AM by M Porter

    Handling exceptions in automatic activities in jBPM 4.2

    Nils Preusker Newbie

      Hi all,


      I'm trying to find out whether there is a solution for the following scenario in jBPM 4.2:


      Let's assume a process uses an automatic activity (with a due date) to call a java method. Now if the java method throws a runtime exception, I want the job executor to suspended the job for a configurable amount of time and then re-execute it. This should be repeated until the method is executed successfully.


      The thread "Handling failure of automated activities" (http://community.jboss.org/message/399271) deals with a similar situation, but the question how to deal with a scenario like this in jBPM 4 is left open.


      Thanks! Nils
        • 1. Re: Handling exceptions in automatic activities in jBPM 4.2
          M Porter Newbie

          This seems to be a common use case as we are trying to implement a similar thing but in a subflow. Unfortunately it wont work as there appears to be a bug in subflows with timers as we modelled a custom java class with a decision node and a process variable to hold the retries. It all works fine until we try and add a timer to make a due transition back to the java class and then it falls over with constraint violation. We are using latest trunk 4.3 as 4.2 breaks subflows with other errors.


          Would be interested to know if anyone has got this to work (especially in a subflow) in 4.2 or 4.3 !!.