cancel
Showing results for 
Search instead for 
Did you mean: 

TaskListener for deleted tasks

brianshowers
Champ in-the-making
Champ in-the-making
I'm trying to write a TaskListener that will watch for all task events (create, assign, and complete).  However, it appears that if a task is cancelled (because the parent process is cancelled), no events are sent to the TaskListener.  As a result, from my listener's perspective, it looks like there are tasks that are created but never closed.

Is it possible to get a notification when tasks are deleted?  Is there a reason that there isn't an event type for 'deleted'?
2 REPLIES 2

frederikherema1
Star Contributor
Star Contributor
There is no particular reason why we don't have an event "deleted". Task-listeners have been in activiti for a long time and we envisioned the common use cases of creating, assigning and completing and didn't take into account the deletion of a task before it is completed (eg. multi-instance completionCondition reached, process deleted, …).

This is a valid improvement. Can you perhaps create a JIRA-issue (improvement) for this?

brianshowers
Champ in-the-making
Champ in-the-making
Thanks for the quick confirmation.  I've created ACT-1560 for this request.  I also created ACT-1561 for a related, but lower priority request to be able to register a listener for all event types without configuring it N times.