-
1. Re: Handling Workflow Exceptions
camunda Nov 8, 2005 10:55 AM (in response to hsf)This means, that the exceptions only can occur in your actions. And this can be handled by the exception handlers from jbpm (sorry, if hhave no no example for this at the moment).
In my opinion it is also a good design to catch business exceptions within your Actions and set some process variables, dependent on what exception is thrown.
Then you can model a Decision in your process, which takes a special path of execution.
And if you talk from RuntimeExceptions (technical issues), don't deal with these in the processes, business processes should be free of those technical issues. -
2. Re: Handling Workflow Exceptions
aguizar Nov 8, 2005 11:04 AM (in response to hsf)You can use exception handlers to affect the data context (e.g. set a flag variable). Alternatively, you can catch exceptions within your "normal" action handlers.
Later on, you can query the context to take a different path of execution (e.g. a decision node checking the value of the flag). -
3. Re: Handling Workflow Exceptions
hsf Nov 8, 2005 8:45 PM (in response to hsf)Okay... I got your point!
But... supose that an administrator deploys a new process definition and someone starts a new execution. Then, the process really needs to be redefined for some very good reason during the execution. How can I handle this situation in jBpm?
I know there are good practises for designing process definitions in order to reduce these situations. But, runtime process exceptions can happen anyway! -
4. Re: Handling Workflow Exceptions
camunda Nov 9, 2005 3:17 AM (in response to hsf)I don't get your real problem.
If a technical, unexpected runtime exception is thrown (and you are working inside a application server) the transaction is rolled back, so the user, triggering the process can get a "Service not available" exception or something like this. This technical exceptions should not be watched at in the business process.
and business exceptions can be handled with the described soltuions -
5. Re: Handling Workflow Exceptions
hsf Nov 9, 2005 10:43 AM (in response to hsf)Okay...
I'm not talking about those runtime exceptions (technical issues). I just wanna know how can the jBpm framework handle with process redefinitions. What happens to the running processes for the redefined definition? Is there any way to change a process definition and consequently affect the running processes?
I hope this explains better my point. -
6. Re: Handling Workflow Exceptions
kukeltje Nov 9, 2005 11:01 AM (in response to hsf)it does, but it would be better if you start a new topic for this question and mention here that you did. This question has no relation with the original subject