Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm trying to install the Commons libraries fileupload and commons-IO.

I have CentOS6 installed and Tomcat version 7.

I managed to download and install the Apache-commons-io package without any problem.

However the apache-commons-fileupload package gave me the servlet_2_4 api dependency issue.

I wonder if installing the new tomcat7-servlet-3 api will cause the above libraries to malfunction since they need the 2.4 version? Or maybe installing the tomcat5 2.4 servlet api will not work with tomcat7?

Which of these two approaches would you recommend?

share|improve this question
up vote 0 down vote accepted

Taken from Oracle's Servlet development guide :

 Servlet API version 3.0 is fully backward compatible with versions 2.3, 2.4, 
 and 2.5, so all existing servlets should work without modification or 

Furthermore, it's stated in the Apache Tomcat 7 documentation that Tomcat 7 specifically implements the Servlet API version 3:

 Apache Tomcat version 7.0 implements the Servlet 3.0 and JavaServer Pages 2.2 
 specifications from the Java Community Process...

Therefore, I'd recommend that you go with version 3 of the Servlet API.

share|improve this answer
Thank you for your reply! It's good to know. Sorry for the late accepting! – Midori Ryuu Sep 28 '12 at 7:29
No worries. I'm glad I could help! – p_strand Sep 28 '12 at 13:46

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .