Problem with reading Jar

Problem with reading Jar

Post by sambitbas » Sun, 04 Apr 2004 10:57:01


I have a third-party jar file weblogic.jar.

On my redhat system, I put it in my $JAVA_HOME/jre/lib/ext and call a
class from anywhere by "java weblogic.Admin". It works just fine.

I do the same on my Mandrake system. But the system complains with
"java.lang.NoClassDefFoundError: weblogic/Admin" exception.

I put it in (say) /export/workarea/classes and added
"/export/workarea/classes/weblogic.jar" explicitly in my class path.
Called "java weblogic.Admin" and got the same
"java.lang.NoClassDefFoundError: weblogic/Admin" exception.

Now, I extract the contents of the jar under
"/export/workarea/classes/weblogic/". I go to
/export/workarea/classes/weblogic/ and issue "java weblogic.Admin".
This time it works fine.

So, it seems the JVM has problem reading Jar. Can anybody give me any
idea as to what's the deal here?

I am using 1.4.1_03. I have tried using the 1.4.2_02 also with same
result.


Thanks,
- Sambit

if you can cc your resonse to my email address too, I'll appreciate
that.
 
 
 

Problem with reading Jar

Post by Jame » Sun, 04 Apr 2004 13:08:37

Just a thought - check if you can possibly be having any classloader issues.