wood burning stoves 2.0*
The moose likes Tomcat and the fly likes Web Application Migration from Tomcat 4.1 to Tomcat 6.0 Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCM Java EE 6 Enterprise Architect Exam Guide this week in the OCMJEA forum!
JavaRanch » Java Forums » Products » Tomcat
Bookmark "Web Application Migration from Tomcat 4.1 to Tomcat 6.0" Watch "Web Application Migration from Tomcat 4.1 to Tomcat 6.0" New topic
Author

Web Application Migration from Tomcat 4.1 to Tomcat 6.0

madhuri ponasanapalli
Greenhorn

Joined: Dec 05, 2008
Posts: 3
Hello ,

I am having trouble migrating by web application from Tomcat 4.1 to Tomcat 6.0 . This application uses struts 1.3.8.

When I deploy the application in Tomcat 6.0 , I get the below error.



If I include the servlet.jar from Tomcat 4.1 in the WEB-INF/lib the application works fine .
Except for the warning validateJarFile(C:\Apache\Tomcat 6.0\webapps\MyApplication\WEB-INF\lib\servlet.jar) - jar not loaded. See Servlet Spec 2.3, section 9.7.2. Offending class: javax/servlet/Servlet.class.

This happens on pages that use the Tiles Layout.

I dont want to use the servlet.jar from Tomcat 4.1 . I want to use the servlet-api.jar & jsp-api.jar from Tomcat 6.0 .

Can anyone please advise .
Thanks
Madhuri

Tim Holloway
Saloon Keeper

Joined: Jun 25, 2001
Posts: 16022
    
  20

Were you attempting to include the Tomcat 6 servlet jar in your webapp?

You shouldn't ever include servlet.jar. If you do, you may experience classpath errors, since the TOMCAT_HOME/lib servlet.jar is in the server's system classpath.

I guess the split between servet-api.jar and servlet-impl.jar must have occurred between Tomcat 4 and Tomcat 5. It's been long enough I don't remember. Web applications should be compiled with the servlet-api.jar in their compile classpath, though the actual jar itself should not be included in the WAR file, since the server's copy will be used at runtime.


Customer surveys are for companies who didn't pay proper attention to begin with.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Web Application Migration from Tomcat 4.1 to Tomcat 6.0