Engine events fired multiple times for one and same building block

Hi all,

I have a simple process with one “start event”, one “user task”, one “manual task” and “end event”.

  1. I have also EngineEventListener. For example “ACTIVITY_STARTED” is fired multiple times for each building block when the process is executed.The “ACTIVITY_COMPLETE” event is fired less times than the start event. Is there a listener that fire only once for each event of the life cycle of the execution of a building block?

  2. In a building block, if I have a TaskListener or ExecutionListener they also fire multiple times the create/start and complete/end events. Is there a built in way to filter them to fire only once?

  3. Suspend process by processInstanceId does not stop the process instance.Why is that? How can I pause the process execution in some listener? I don’t want to use UsertTask or ReceiveTask so they automatyically set the process in “Wait” state. I want to manually change the state and in the same second as the method “SuspendProcessByProcessInstanceId” is executed, the instance to be suspended and no further building block to be executed for this process instance. I have a manual task and want into it’s listener to stop the process. How can Ido it, or maybe directly to set the process instance to goes into a “WAIT” state somehow?

Thanks in advance


  1. When you say “The “ACTIVITY_COMPLETE” event is fired less times than the start event.”. Is this for a completed process or a process that has stopped in the user task? When the process is done you should have the same number of ACTIVITY_STARTED and ACTIVITY_COMPLETED events. Are you saying that for the user task you have multiple ACTIVITY_STARTED events?

  2. Within a process and a single activity the listener should fire only once for the create or start events (same for the end).

  3. If you are suspending the process instance from within a listener you won’t achieve what you are trying to do. And no you can’t manually create a “WAIT” state. Why not use a user task instead of a manual task? Let’s imagine that you could somehow stop the process in a manual task, how would you continue executing the process further?

Is it somehow possible for you to create a small reproducing test case that we can have a look?


Hi filiphr,

Thanks for your reply.
I fixed it. I have another listener on the start event and it cause all the troubles.
Now it is OK. Thanks