3 Replies Latest reply on Mar 16, 2014 8:39 AM by clandestino_bgd

    JBPM6 as a library

    clandestino_bgd

      Hello,

      I am an old JBPM v3 and v4 user and I am also using Spring and Tomcat in my everyday developer life.

      Now, I know things changed quite a bit since v5, but I am starting a new BPM project in the next couple of weeks and I need to evaluate available OS BPMs.

      JBPM6 is definitely on my list, since it is full of very advanced features.

      My aim is to use it as a library sharing DB and EMF with my other spring beans and deploy it on vanila tomcat 7 on Amazon EC2.



      I tried to find but without much luck a sample spring project deployable under tomcat that has:

      - JBPM 6 RuntimeManager configured in spring application context

      - without JTA, JNDI, bitronix, etc. I'd like to use Spring transaction manager

      - without JAAS (I'd like to plugin the Identity Component through spring security. Is that possible at all?)

      - without CDI.

      - with shared entity manager

       

      If there is no such thing, could you please advise if this is doable without significant effort.

       

      I've found the configuration snippets here:

      http://planet.jboss.org/post/jbpm_6_with_spring

      It suggests that spring factories will be implemented in version 6.1.0.

      What would be the planned release date?

       

      Thanks,

      Milan






       

        • 1. Re: JBPM6 as a library
          swiderski.maciej

          that is certainly possible, as described in that article and I believe there is already a beta 1 of 6.1.0 available in maven so feel free to check it out and get back to us in case of something that is still missing or does not work as expected.

           

          Milan Agatonovic wrote:

          - without JAAS (I'd like to plugin the Identity Component through spring security. Is that possible at all?)

           

          yes, you just need to provide your own implementation of UserGroupCallback and register it on the RuntimeEnvironment that is then used to create RuntimeManager.

           

          HTH

          • 2. Re: JBPM6 as a library
            clandestino_bgd

            Thanks!

             

            Maciej Swiderski wrote:

             

            that is certainly possible, as described in that article and I believe there is already a beta 1 of 6.1.0 available in maven so feel free to check it out and get back to us in case of something that is still missing or does not work as expected.

             

            Knowing that it's certainly possible helps.

            I thought 6.1.0.Beta1 is not released, since it is not marked in JIRA, anyway I cloned 6.1.0.Beta1 tag from github but build fails.

             

            My environment is:

            Mac OSX 10.8.2

            java version "1.7.0_17"

            Java(TM) SE Runtime Environment (build 1.7.0_17-b02)

            Java HotSpot(TM) 64-Bit Server VM (build 23.7-b01, mixed mode)

            Maven 3.0.5

             

            Running org.kie.spring.tests.KieSpringBasicsTest

            Tests run: 1, Failures: 1, Errors: 0, Skipped: 0, Time elapsed: 0 sec <<< FAILURE! - in org.kie.spring.tests.KieSpringBasicsTest

            org.kie.spring.tests.KieSpringBasicsTest  Time elapsed: 0 sec  <<< FAILURE!

            java.lang.AssertionError: null

              at org.junit.Assert.fail(Assert.java:86)

              at org.junit.Assert.assertTrue(Assert.java:41)

              at org.junit.Assert.assertNotNull(Assert.java:621)

              at org.junit.Assert.assertNotNull(Assert.java:631)

              at org.kie.spring.tests.KieSpringBasicsTest.setup(KieSpringBasicsTest.java:40)

             

            In addition

            Tests in error:

              JTAEntityManagerSpringTest.testSpringWithJTAAndEM:37 » IllegalState Not allowe...

              JTAEntityManagerSpringTest.testSpringWithJTAAndEMwithRollback:83 » IllegalState

              LocalEntityManagerFactorySpringTest.testSpringWithJTAAndEMFwithRollback:94 » BeanCreation

              LocalEntityManagerFactorySpringTest.testSpringWithJTAAndEMF:39 » BeanCreation ...

              LocalEntityManagerSpringTest.testSpringWithJTAAndEM:34 » BeanCreation Error cr...

              LocalEntityManagerSpringTest.testSpringWithJTAAndEMwithRollback:79 » BeanCreation

             

             

            yes, you just need to provide your own implementation of UserGroupCallback and register it on the RuntimeEnvironment that is then used to create RuntimeManager.

             

             

            Thanks, but is there a springified example where some UserGroupCallbackImpl bean is defined in spring app context. Where it should be injected to?

             

            best,

            Milan

            • 3. Re: JBPM6 as a library
              clandestino_bgd

              Hi, I'll try to provide test error logs here.

              Judging by test class names it looks like my use cases are covered in tests org.kie.spring.jbpm.LocalEntityManagerFactorySpringTest and org.kie.spring.jbpm.LocalEntityManagerSpringTest

               

              kie spring 6.1.0.Beta1 test

               

              Hope you can help me here.

              Thanks,

              Milan