• Post Reply Bookmark Topic Watch Topic
  • New Topic

Tomcat 5.5 Class loading issues--and I have done some home work on this one  RSS feed

S. Smith
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have two filters within my web.xml--one uses a sitemesh plugin and the other uses a wikiUrlSessionIdFilter plugin---from sitemesh.jar and jboss-seam.jar respectively. If I place the two jars in tomcat/common/lib directory and start the server, I get ClassNotFoundExceptions when Tomcat tries to create servlets for the filters. If I move the jars to the application's WEB-INF/lib directory, I get ClassCastException when Tomcat tries to create servlets for the filters. And yes this war works just fine under Tomcat 5.0.28---where both jars only reside in tomcat/common/lib.
I have checked for multiple instances of these jars throughout the application and there are none. The jars do not exist in any other tomcat directory. The jars are not on the CLASSPATH either and from what I understand, Tomcat 5.5 does not use the CLASSPATH anymore by default. I have checked that the jars are the latest version--good to use with Tomcat 5.5---and they are. I have double and triple checked that these jars are not being indirectly packaged in the war somehow. I use Eclipse to do a basic build of the war---same as I did for Tomcat 5.0---except now I deploy to a Tomcat 5.5 server.
So far, I have worked through several issues of migrating from Tomcat 5.0 to 5.5 (logging changes, class loading changes, dependent jar changes, inconsisent jar issues, jasper jar issues, etc, etc, etc) and I am now completely at a loss on this one. I know it is some sort of class loading issue, but I have no idea if I can solve it and how. I cannot seem to figure out what Tomcat wants.
Tomcat 5.5 acts as if he has to have the jars in the application lib, but is confused when it uses those--like it alreay loaded the classes before, from somewhere else. In case it matters---I am starting Tomcat natively on Windows using startup.bat
Anyone got any ideas on this---I could sure use some help?
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!