cancel
Showing results for 
Search instead for 
Did you mean: 

How to implement cancel workflow?

singhneha17
Champ in-the-making
Champ in-the-making
Hi folks,

There are a lot of topics in the forum discussing strategies for implementing 'Cancel' in business workflows.
Is there a graceful way to implement a 'cancel' functionality where in an event can be raised in the workflow, hence pausing the normal workflow ? something like an interrupt, which can be raised at any time during the workflow.
2 REPLIES 2

albertorugnone1
Champ in-the-making
Champ in-the-making
This is an interesting question. Any answer?! pleeeeeease   :mrgreen:

mdaviot
Champ in-the-making
Champ in-the-making
I am not sure to understand your context, but here is what I did.

We have an order manager which handles confirmation, payment, shipping …

The business rule is the customer can cancel his order until it has been shipped.

This part of the process (before shipping) is defined in a subprocess. This subprocess has a signal interrupting event (message interrupting event would be more relevant but was not implemented in Activiti 5.9) which is triggered by the cancel order button in the GUI.

So my suggestion is to encapsulate the part(s) which can be cancelled in a subprocess, and define an interrupting event on this subprocess.

If you are interested I can provide an example. In particular there is some specific code involved to trigger the interrupting event using Activiti API.