you can put state node in between the java nodes and if you don't like to signal it manually later on put a timer on transition from state node that will trigger to move on. Simple but perhaps it will be acceptable in your case.
thanks for the reply. In our situation what we want when we shutdown the jboss server all the current jBPM processes should be suspended and later continue when we again the start the jboss server.
For this what we have done is created an jboss MBean. In the stop method of the MBean we are getting all the process running process instances using the jBPM query API and we are calling the processEngine.close(); method. So what is happening is our Mbeans stop method is paused till all the running processes are completed.
Is there any way by which i can use the API to move our running process into a wait state?