• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Problem with jar-files

 
Sheriff
Posts: 11604
178
Hibernate jQuery Eclipse IDE Spring MySQL Database AngularJS Tomcat Server Chrome Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello,

I am working with Tomcat 4.1.29 and i have some jar-files that are used by my 2 web-apps. So i placed these jars into %tomcat_home%/common/lib and into %tomcat_home%/shared/lib, but then my webapps won't work anymore. I even unzipped them and placed those classes into %tomcat_home%/common/classes and %tomcat_home%/shared/classes (including the directory structure according to package name), but that's also not working.

when i place this jar's into the lib-directory of both my apps, those work just fine.

Does anyone has a clue ???
 
Author and all-around good cowpoke
Posts: 13078
6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
"won't work anymore" - what (exactly) happens? If you get error messages in logs, what is the cause?
Bill
 
Roel De Nijs
Sheriff
Posts: 11604
178
Hibernate jQuery Eclipse IDE Spring MySQL Database AngularJS Tomcat Server Chrome Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
On the first line of my web-app where such a class is called (a class in a jar under tomcat_home/common/lib) he returns this error

HTTP Status 500 - Dispatch[/kaart] to method init returned an exception

--------------------------------------------------------------------------------

type Status report

message Dispatch[/kaart] to method init returned an exception

description The server encountered an internal error (Dispatch[/kaart] to method init returned an exception) that prevented it from fulfilling this request.


--------------------------------------------------------------------------------

Apache Tomcat/4.1.29

So my guess is: he can't find the class but it's certainly there
 
author
Posts: 3252
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Surely there's a stack trace in the Tomcat log?

- Peter
 
Roel De Nijs
Sheriff
Posts: 11604
178
Hibernate jQuery Eclipse IDE Spring MySQL Database AngularJS Tomcat Server Chrome Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
i checked all my logs and there is nowhere any stackthrace
 
Roel De Nijs
Sheriff
Posts: 11604
178
Hibernate jQuery Eclipse IDE Spring MySQL Database AngularJS Tomcat Server Chrome Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I fixed it myself.

Solution:

my classes under the %tomcat_home%/common/lib are
be.aqf.a.A
be.aqf.b.B

in the jar that's in the lib-directory of my web-apps there are also several classes in the same package as above, so for example:
be.aqf.a.AA
be.aqf.a.AAA
be.aqf.b.BB

So i changed the following
be.aqf.a.A into be.aqf.c.A
be.aqf.b.B into be.aqf.c.B

then jarred them up and placed it under the %tomcat_home%/common/lib directory and it's working fine. So i conclude that packages are overwritten are something like that !?

Thanks for the help.
 
reply
    Bookmark Topic Watch Topic
  • New Topic