Maciej Swiderski [
https://community.jboss.org/people/swiderski.maciej] created the
discussion
"Re: Not able to start a process through the Java API"
To view the discussion, visit:
https://community.jboss.org/message/796801#796801
--------------------------------------------------------------
Jose Miguel Loor wrote:
private StatefulKnowledgeSession getKSession(final String changeSetUrl) throws
ProcessRulesException {
StatefulKnowledgeSession ksession =
getKBase(changeSetUrl).newStatefulKnowledgeSession();
ksession.getWorkItemManager().registerWorkItemHandler("Human Task", new
SystemOutWorkItemHandler());
return ksession;
}
Here you have two issues:
1. you create non persistence session and thus nothing ends up in data base
2. use SystemOutWorkItemHandler as handler for human tasks so it will simply print its
properties and move on with the next nodes, most likely ending up as completed process
instance
Take a look in the docs on how to setup persistent sessions and make sure that it's
configured towards the same db as console.
HTH
--------------------------------------------------------------
Reply to this message by going to Community
[
https://community.jboss.org/message/796801#796801]
Start a new discussion in jBPM at Community
[
https://community.jboss.org/choose-container!input.jspa?contentType=1&...]