Timer start event to increase the monitoring problem

Yes, here I am again.
When I use Timer start event,I want to get processInstanceId.But,it’s NulPointerException.

Hi @wisdom ,

Did you try to pick the process instance object directly from the delegateExecution object.
delegateExecution.getProcessInstance()

I believe that the process instance is not committed yet to the database at this stage (start event) so querying it will return nothing.

Thank you for your answer.
Yes, I found that the null value was caused by not submitting to the database. I will try this method you provided.

wisdom

1 Like