[rules-users] how to get a list of incomplete workitems after e.g server/process crash?

gs76pl gstasica at pacemetrics.com
Tue Apr 19 06:33:32 EDT 2011


i tried to load the session from a store like below and then query it for
work items/nodes but it doesn't give me an access to e.g. workItem
parameters as this value is empty.

Is there any API that would provide this information or should i somehow
duplicate drools flow and try to use NodeListeners? I'm sure there must be
some way of querying crashed process where it was so it could be resumed
using workItem.complete api

StatefulKnowledgeSession session = kbase.loadStatefulKnowledgeSession(....)
for (NodeInstance n : ((WorkflowProcessInstance)
getKnowledgeSession().getProcessInstance(1)).getNodeInstances()){
    WorkItem w = ((WorkItemNodeInstance)n).getWorkItem();
//w is null here so i don't have an access to its parameters
}

--
View this message in context: http://drools.46999.n3.nabble.com/how-to-get-a-list-of-incomplete-workitems-if-one-of-them-crashed-e-g-server-restart-tp2835230p2838237.html
Sent from the Drools: User forum mailing list archive at Nabble.com.



More information about the rules-users mailing list