0 Replies Latest reply on Mar 13, 2013 4:18 PM by jamesbeam

    Is Drools/JBPM Tooling for Eclipse broken with JPAKnowledgeService?

      I am trying to use the Drools/JBPM tooling to test a simple program with jBPM 5.4.  I tried this in Eclipse Helios and Juno.

       

      If I create the ksession using kbase.newStatefulKnowledgeSession() the drools views work as expected - the process and process instances show the correct information (after I click on the ksession in the variables window of course).  However, this does NOT work if I create the the ksession using the JPAKnowledgeService.

       

      Is this a known issue/limitation?  Am I missing something?

       

      code:

          KnowledgeBuilder kbuilder = KnowledgeBuilderFactory.newKnowledgeBuilder();

          kbuilder.add(ResourceFactory.newClassPathResource("Test.bpmn"),ResourceTypoe.BPMN2);

          Environment env = KnowledgeBaseFactory.newEnvironment();

          env.set(EnvironmentName.ENTITY_MANAGER_FACTORY,emf);

       

          StatefulKnowledgeSession ksession = kbase.newStatuefulKnowledgeSession();   <-- THIS WORKS FINE

       

           --- BUT --

       

           StatefulKnowledgeSession ksession = JPAKnowledgeService.newStatefulKnowledgeSession(kbase,null,env);  <---THIS DOES NOT

       

      Note, when I use the JPAKnowledgeService, my app does function correctly (I see the session being updated in the database, etc).

       

      Also, I tried creating the first ksession above first (calling it ksession2) and then setting ksession2=ksession, and everything works until the assignment, then the tooling stops responding.

       

      Any thoughts on how to get this to work?

       

      Thanks!   -J