delete and complete task listener both fire

cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Active Member II

delete and complete task listener both fire

delete and complete  task listener both fire   in case of complete a userTask ?

here i am attached a test.bpmn20.xml in  which  have 2 userTask  a and b.

userTask a have a boundary timer event and a also have 2 listener . one is fire when task deleted and anther is completed  

if i am complete userTask a then both  listener fire .

why both listener fire?

i think only  completed listener should be fire.

if because of timer deleted listener fire so how to deactivate or stop timer job before complete the userTask? 

1 Reply
Highlighted
Senior Member

Re: delete and complete task listener both fire

> if i am complete userTask a then both listener fire .
> why both listener fire? i think only completed listener should be fire.

It's the behavior as specified.
If a userTask is completed, the process engine deletes a task entity and a task entity delete event fires.

> if because of timer deleted listener fire so how to deactivate or stop timer job before complete the userTask?

I'm sorry that I cannot understand your fear.
If you complete the userTask before timer job fire, you don't need care of timer job.