[jboss-user] [jBPM] - How to resume a persisted processInstance?

Ryan Peterson do-not-reply at jboss.com
Fri Sep 16 19:53:19 EDT 2011

Ryan Peterson [http://community.jboss.org/people/rrpeterson] created the discussion

"How to resume a persisted processInstance?"

To view the discussion, visit: http://community.jboss.org/message/627001#627001

Hey guys,

I'm starting my ProcessInstance which consists of two service tasks seperated by a timer.  

If I Thread.sleep() after creating my StatefulKnowledgeSession before calling ksession.dispose(), then the timer can complete and my 2nd task executes.

If I call ksession.dispose() without sleeping, and re-load my ksession via JPAKnowledgeService.loadStatefulKnowledgeSession(w, x, y, z), my processInstance gets stuck on the timer even though more time has elapsed than it's limit.  Is there a method I need to call in order to get my processInstance to continue executing upon checking the timer status?

Ideally I'd like to be able to create and start my processInstance, then close out the ksession.  Then periodically check on the status of the ksession to see if the timer's value has elapsed, and if so continue executing nodes.

Thanks for any suggestions/help!

Reply to this message by going to Community

Start a new discussion in jBPM at Community

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-user/attachments/20110916/6317b0a6/attachment.html 

More information about the jboss-user mailing list