posted 16 years ago
I'm not sure if I read that correctly, but here's a stab:
If you produce an executable JAR, all the resources (classes, property files, images, etc.) in that JAR will be placed in the app's CLASSPATH when you run the jar with the "java -jar jarfile" option.
Libraries, however, will not. They'll be visible on the classpath, but the app can't load or use their contents.
Fortunately, someone - or maybe several someones - have realized that this is a problem and that Maven can fix it. I haven't yet got the process all worked out, but apparently there's a Maven plug-in that can cause a custom classloader to be integrated into your app that peers inside the JARS and adds their contents to the classpath.
The secret of how to be miserable is to constantly expect things are going to happen the way that they are "supposed" to happen.
You can have faith, which carries the understanding that you may be disappointed. Then there's being a willfully-blind idiot, which virtually guarantees it.