This week's book giveaways are in the Java EE and JavaScript forums.
We're giving away four copies each of The Java EE 7 Tutorial Volume 1 or Volume 2(winners choice) and jQuery UI in Action and have the authors on-line!
See this thread and this one for details.
The moose likes Other Java Products and Servers and the fly likes Servlet calls jar method but NoClassDefFoundError occurs Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of The Java EE 7 Tutorial Volume 1 or Volume 2 this week in the Java EE forum
or jQuery UI in Action in the JavaScript forum!
JavaRanch » Java Forums » Products » Other Java Products and Servers
Bookmark "Servlet calls jar method but NoClassDefFoundError occurs" Watch "Servlet calls jar method but NoClassDefFoundError occurs" New topic
Author

Servlet calls jar method but NoClassDefFoundError occurs

Rogerio Kioshi
Ranch Hand

Joined: Apr 12, 2005
Posts: 689
The servlet calls a jar method. This method is inside a class which is inside th jar. This class uses others libs (jars) which are inside Glassfish lib path, but I'm getting "NoClassDefFoundError" error...

Could it be a classloader problem? Is it possible changing Webcontent\META-INF\MANIFEST.MF file content in the java web app can solve my problem?


SCEA 5 (part 1), SCBCD, SCWCD, SCJP, CLP, CLS
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61082
    
  66

If you are getting that error then the class is simply not there.


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
Rogerio Kioshi
Ranch Hand

Joined: Apr 12, 2005
Posts: 689
Bear Bibeault wrote:If you are getting that error then the class is simply not there.


But is is there... I've already checked many times...
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61082
    
  66

I seriously doubt that you've found a class loader bug. I'll move this to a more specific forum where the Glassfish-savvy may be able to help you.
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: Servlet calls jar method but NoClassDefFoundError occurs