0
votes

Ok I'm having quite some issues setting both jbpm and jboss working together...something as simple as running the jbpm process from a servlet is trunning to be a pain and all because jBoss can't find classes.

I made a Dynamic Web Project and didn't use Maven project so things are cleaner...and because it should work.

I just want to load a jbpmn2.0 from the repository in a servlet and run it using a WorkItemHanlder....but I get this:

java.lang.ClassNotFoundException: org.drools.runtime.process.WorkItemHandler

For some reason jBoss can't find a class from jBPM that should work on JBoss. What I did....and I think it's not the right solution...was add the knowledge-api.jar to the WEB-INF/lib. Although I can now deploy the app when I try to run it I get:

Error Unable to instantiate service for Class 'org.drools.builder.KnowledgeBuilderFactoryService'

I Honestly don't get why is it so hard to make a Jboss Web app using jBpm.

1

1 Answers

1
votes

You need to make sure all dependencies are on your classpath, this is the same for all Java applications (not just jbpm) and application servers (not just JBossAS).

Which jars did you add? Depending on which features you are using, there could be quite a number of jars that you need to add. One option would for example would be to extract the jars in the jBPM runtime zip that is part of the jBPM downloads into your WEB-INF/lib.

If you use Maven, you would be able to automatically derive all required jars.

Kris