4 Replies Latest reply on Apr 28, 2011 10:48 AM by SaeedAhmed Subedar

    Using JSP front end with JBPM, Tomcat

    SaeedAhmed Subedar Newbie

      Hi everyone,

       

      I am unable to add Jbpm 5 libraries to my JSP application on tomcat 6 using eclipse. An example implementation would be ideal.

       

      Thanks very much,

      Saeed

        • 1. Using JSP front end with JBPM, Tomcat
          Mauricio Salatino Master

          Hi there, what kind of problem are you having?

          If we provide an implementation using JSP, there will be another person that will require to show something using JSF, etc, etc.

          I personally prefer to help you with your specific problem. If you want you can take a look at :

          https://github.com/Salaboy/emergency-service-drools-app

           

          It's swing and slick 2d implementation using jBPM5 and Drools.

          Greetings.

          • 2. Using JSP front end with JBPM, Tomcat
            SaeedAhmed Subedar Newbie

            Thanks for the app. My problem is that when I try to add some jbpm library jars to my web app on tomcat through eclipse, I am unable to run the app. I  get the foll. error..

             

            java.lang.ClassNotFoundException: org.drools.event.KnowledgeRuntimeEventManager

             

             

            I want to know which are the exact Jbpm 5 libraries I need to add to the build path. As of now I have added jbpm-5.0.0-bin.zip. It seems that the zip file is not being read by tomcat, as a result of which I have added specific jars, drools-api-5.2.0.M1.jar and drools-compiler-5.2.0.M1.jar into the path.

             

            I think "-Djbpm.console.directory=${install.home}/sample/evaluation/src/main/resources" property also needs to be set somewhere on tomcat. And the bpmn file needs to be places in the jbpm console directory.

             

            To add to this, in the jbpm 5 installer eclipse, I am unable to create a web project. So bmpn file would have to be created here and integrated into an external eclipse web application.

             

             

            Thus, I would find a web custom UI jbpm 5 example very helpful, especially from configuration and deployment perspective.

            • 3. Using JSP front end with JBPM, Tomcat
              Mauricio Salatino Master

              if you create your web application using maven it will get all the required dependencies from you.

              If you want to take a look at a web application using jBPM5 you can take a look at the jBPM5 console that it's using it.

              You can't include zip files in your classpath, you probably need to include all the jars provided in the binary distribution of jBPM5 to make it work. Not all of them will be required to run a simple processes but at least you will not get the ClassNotFoundExceptions.

              Greetings.

              • 4. Using JSP front end with JBPM, Tomcat
                SaeedAhmed Subedar Newbie

                I am adding jars individually from those included in jbpm5 console app. library. This is working for me.

                 

                 

                The bpmn file is not being read by my web app (on Tomcat)

                 

                I am getting foll. error..

                 

                java.lang.NullPointerException

                    at org.drools.compiler.PackageBuilder.addProcessFromXml(PackageBuilder.java:430)

                    at org.drools.compiler.PackageBuilder.addKnowledgeResource(PackageBuilder.java:470)

                    at org.drools.builder.impl.KnowledgeBuilderImpl.add(KnowledgeBuilderImpl.java:28)

                 

                on using the code..

                 

                kbuilder.add(ResourceFactory.newClassPathResource("sample.bpmn"), ResourceType.BPMN2);

                 

                 

                A simple web jbpm 5 implementation other than jbpm5 console app. would be easier to understand and get going..

                 

                Thanx.