Timer Boundary and Catching Event usage from Java code

Hey Jacopo,

Correct me if I am wrong, but is your question similar to Catch the event of a blocked instance only after a timeout?

Your example is not OK since you are blocking in your service task? Which is not a wait state and the engine will wait for it’s execution before continuing, this means that the timer task won’t even be created since you are in a running state of the process.

You would have to handle the waiting and proceeding in your own java logic.

Btw, you don’t need to manually execute the job. The reason why it is done like that in the tests is to simulate the events. You can also see that every test that Martin linked has a User task as a wait state. This means that the engine will first do a commit and give back the control of the process execution.

Cheers,
Filip