Re: Required jars on CLASSPATH?

Tim Anderson <[email protected]> Sat, 04 Nov 2006 22:13:09 +1100
Newsgroups gmane.comp.java.openjms.user
Message-ID <[email protected]>
Dave Syer wrote:
> I looked at the way the examples work, and the run script seems to only
> include one jar file on the CLASSPATH (openjms-0.7.7-alpha-3.jar).  But this
> jar does not contain some classes that appear to be necessary for the
> examples to run.  When I try to write my own very simple example I find that
> I cannot even create an initial context because org.exolab.jms.net.URI is
> missing.  What is going on with the examples?
>
> It seems as if there is some sneaky discovery going on to find the location
> of the openjms libraries, and they are somehow being added to the classpath
> after the JVM start up.  How does that work?
>   
The sneaky discovery you're referring to is the Class-Path: entry in the 
openjms-0.7.7-alpha-3.jar MANIFEST.MF
file. Its a standard way of describing a jar's dependencies.
See http://java.sun.com/docs/books/tutorial/deployment/jar/downman.html 
for more details.
> More importantly, what is the real list of dependencies for the examples?  I
> found an m2 deployment of openjms-client at version 0.7.6 on ibiblio,
> thinking that might be a good place to discover dependencies (openjms
> appears to be using m2).  But that didn't help because the pom has no
> dependencies in it.  Is this something that could easily be provided?  I
> would really like to be able to use m2 to build my project, so it would help
> a lot if the dependencies were explicit.
>   
OpenJMS is built with maven 1.0.2.
The list of jars required for clients is listed here: 
http://openjms.sourceforge.net/usersguide/jars.html

-Tim


-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642