cancel
Showing results for 
Search instead for 
Did you mean: 

How to invoke task listener for custom events

studious
Champ in-the-making
Champ in-the-making
Hi,
I am trying to invoke task listener for events such as Suspend. How can I do that? I extended the task listener. But
when I give the event name in the bpmn file it gives an error. I see it allows only create, assign and suspend.
<activiti:taskListener event="suspend" class="org.listener.MyTaskListener"></activiti:taskListener>
How can I invoke the listener when the event is Suspend ?
1 REPLY 1

frederikherema1
Star Contributor
Star Contributor
Suspending is not an actual event. We only support the events that are listed in the user guide. You should add a layer on top of the Activiti API which does any additional logic in your own code, when the suspendProcess() or suspendProcessDefinition() is called.