Hi Mauricio,

I am setting my "env" the following way:
                env = KnowledgeBaseFactory.newEnvironment();
                env.set(EnvironmentName.ENTITY_MANAGER_FACTORY, emf);
                env.set(EnvironmentName.GLOBALS, new MapGlobalResolver());

My registerWorkItemHandlers() method registers workItemHandlers the
following way:

                manager.registerWorkItemHandler("SomeHandler", new 
SomeHandler());
                manager.registerWorkItemHandler("SomeOtherHandler", new
SomeOtherHandler());

After configuring the environment and registering the workItemHandlers I
reload the Session as follow:

ksession = JPAKnowledgeService.loadStatefulKnowledgeSession( SESSION_ID,
knowledgeBase, null, env );

I am using the same knowledgeBase I used to originally start the workflow,
the sessionId is the correct as I can see this on the DB, and I think I'm
setting the "env" correctly as well.

I hope this gives you a better picture of what is going on.

Please let me know if you have any questions.

Thanks,

Nick.

P.S. I agree with Tolitius... if I don't have any "Parameter Mapping"
variables going in the workItem it runs fine. But whenever I have a
Parameter Mapped for the workItem I get this error.
 
-- 
View this message in context: 
http://n3.nabble.com/Resuming-Flow-NPE-when-completing-a-work-item-tp716847p717407.html
Sent from the Drools - User mailing list archive at Nabble.com.
_______________________________________________
rules-users mailing list
rules-users@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users

Reply via email to