-
1. Re: JBPM-BPEL process monitoring - engine API
aguizar Oct 10, 2007 7:41 PM (in response to ruhl22)The jBPM BPEL runtime inherits the engine API provided by jBPM jPDL. The class JbpmContext is the (pojo) facade to the publicly available process operations. The so-called "named" sessions, available from the jbpmContext object, encapsulate different categories of database access. The GraphSession provides methods to retrieve the deployed process definitions and the running process instances. A sample includes:
findAllProcessDefinitions()
findLatestProcessDefinitions()
findProcessInstances(processDefinitionId) -
2. Re: JBPM-BPEL process monitoring - engine API
ruhl22 Oct 11, 2007 2:31 AM (in response to ruhl22)Thanks for your reply. This helps a lot.
What about process administration functionality? Is there a way (API) to start/stop deployed/running processes?
Kind regards, ruhl22. -
3. Re: JBPM-BPEL process monitoring - engine API
ruhl22 Oct 11, 2007 2:43 AM (in response to ruhl22)I have inspected the mentioned classes, my previous question is obsolete.
Thanks again, ruhl22. -
4. Re: JBPM-BPEL process monitoring - engine API
ruhl22 Oct 11, 2007 10:18 AM (in response to ruhl22)Hi Alex.
I have implemented a session bean facade and deployed it to the jboss server, where the jbpm-bpel engine runs. Additionally, using a client application, I access the method exposed by the deployed session bean.
Everything runs as imagined, except that I get an exception (related to hibernate lazy collection initialization) when trying to access the Actions of a BpelProcess.Clinent code: Map<String, Action> actionMap = bpelProcessTemplate.getActions(); actionMap.size(); //exception flies here.
The exception stack is:Exception in thread "main" org.hibernate.LazyInitializationException: failed to lazily initialize a collection of role: org.jbpm.graph.def.ProcessDefinition.actions, no session or session was closed at org.hibernate.collection.AbstractPersistentCollection.throwLazyInitializationException(AbstractPersistentCollection.java:358) at org.hibernate.collection.AbstractPersistentCollection.throwLazyInitializationExceptionIfNotConnected(AbstractPersistentCollection.java:350) at org.hibernate.collection.AbstractPersistentCollection.readSize(AbstractPersistentCollection.java:97) at org.hibernate.collection.PersistentMap.size(PersistentMap.java:95) at com.agetas.jbpm.client.Run.main(Run.java:83)
Do you have any idea, how I can prevent this exception to occur? I don't want to modify the hibernate mapping code of the classes within jbpm-jpdl.jar, to deactivate lazy loading...
Thanks in advane, ruhl22.