-
1. Re: how to specify external jar files for ActionHandlers
koen.aers Apr 11, 2006 11:47 AM (in response to shavianshakes)You should simply make sure they are on the classpath.
Regards,
Koen -
2. Re: how to specify external jar files for ActionHandlers
shavianshakes Apr 11, 2006 3:16 PM (in response to shavianshakes)I had already added the jars to the classpath ( in Eclipse -> -> Properties -> Java Build Path -> Libraries and "Order and Export"). I hope these are the right places to add. Also they are added to the the $CLASSPATH variable on my linux development system. The build/compile is just fine, but it is at runtime that the error is generated. Do I need to add the jars elsewhere ?
btw, my JUnit test case which walks the workflow runs just fine.
I also looked up the code in ProcessClassLoader.java where the error is being generated:49 public Class findClass(String name) throws ClassNotFoundException { 50 Class clazz = null; 51 52 FileDefinition fileDefinition = processDefinition.getFileDefinition(); 53 if (fileDefinition!=null) { 54 String fileName = "classes/" + name.replace( '.', '/' ) + ".class"; 55 byte[] classBytes = fileDefinition.getBytes(fileName); 56 clazz = defineClass(name, classBytes, 0, classBytes.length); 57 }
It happens at line 55. Not sure though what to make of it.
thanks. -
3. Re: how to specify external jar files for ActionHandlers
shavianshakes Apr 11, 2006 6:06 PM (in response to shavianshakes)I got it to work by modifying the classpath in the run.sh for starting jboss:
JBOSS_CLASSPATH="$JBOSS_BOOT_CLASSPATH:/mypath/myjar.jar
I am sure there is a better way to do this but am unable to find it in the docs.
thanks. -
4. Re: how to specify external jar files for ActionHandlers
hosierdm Apr 11, 2006 6:49 PM (in response to shavianshakes)If you are running the process in JBoss, just stick the jar file in the server//lib directory. I think that should work with a "normal" classloading scheme in JBoss.
-
5. Re: how to specify external jar files for ActionHandlers
koen.aers Apr 12, 2006 2:34 AM (in response to shavianshakes)Yes, this would be the best way if you don't want to modify the webapp. Put the jars in the '%jbpm_server_home%/server/jbpm/lib' folder where '%jbpm_server_home%' is the location where you extracted your starter's kit. Another possibility is to rebuild the webapp and put the jars in the WEB-INF/lib folder of your war file.
Regards,
Koen