servlet各个版本支持jstl

最近在做一个java web的项目,发现不同的servlet版本下要支持jstl依赖的jar包是不同的,现在记录下,以免忘记。

Java  EE版本介绍

此章节内容来自于 http://www.javasprint.com/java_training_tutorial_blog/java_jee_versions_jsp_servlet_story_jsf_jstl_el_history.htm和 http://en.wikipedia.org/wiki/Java_EE_version_history

Different versions of JEE:

Note: JPE (Java Professional Edition) project announced in May 1998 at Sun Microsystems.

Version Released in          
JEE2 (J2EE 1.2) 12 Dec 1999 Servlet 2.2 JSP 1.1      
JEE3 (J2EE 1.3) 24 Sep 2001 Servlet 2.3 JSP 1.2   JSTL 1.0  
JEE4 (J2EE 1.4) 11 Nov 2003 Servlet 2.4 JSP 2.0   JSTL 1.1 JSF1.1
JEE5 11 May 2006 Servlet 2.5 JSP 2.1 EL2.1 JSTL 1.2 JSF 1.2
JEE6 10 Dec 2009 Servlet 3.0 JSP 2.2 EL 2.2 JSTL 1.2 JSF 2.0
JEE7 12 Jun 2013 Servlet 3.1 JSP 2.3 EL 3.0 JSTL 1.2 JSF 2.2

JEE and TOMCAT:

Lets only look at servlet and JSP versions in JEE as it compares to in TOMCAT.

JEE Version TOMCAT Version
JEE3 implements Servlet 2.3 and JSP 1.2 Tomcat 4 supports the same (Servlet 2.3 and JSP 1.2)
JEE4 implements Servlet 2.4 and JSP 2.0 Tomcat 5 supports the same
JEE5 implements Servlet 2.5, JSP 2.1, JSTL 1.2, JSF 1.2 Tomcat 6 supports Servlet 2.5, JSP 2.1 only. No JSTL. No JSF
JEE6 implements Servlet 3.0, JSP 2.2, EL 2.2, JSTL 1.2, JSF 2.0 Tomcat 7 supports Servlet 3.0, JSP 2.2, EL 2.2 as well

Servlet各个版本使用jstl

Servlet 2.4

web.xml中的scheme定义

maven中的依赖
    
        javax.servlet
        jstl
        1.1.2
    

    
      taglibs
      standard
      1.1.2
    

Servlet 2.5

web.xml中的scheme定义


maven中的依赖
    
        javax.servlet
        jstl
        1.2
    

Servlet 3.0

web.xml中的scheme定义
 
maven中的依赖(来自于 http://www.murraywilliams.com/2011/11/running-jstl-1-2-on-tomcat-7-using-maven/)

    javax.servlet
    javax.servlet-api
    3.0.1
    provided



    javax.servlet
    jstl
    1.2



    org.glassfish.web
    jstl-impl
    1.2
    
        
            servlet-api
            javax.servlet
        
        
            jsp-api
            javax.servlet.jsp
        
        
            jstl-api
            javax.servlet.jsp.jstl
        
    



你可能感兴趣的:(java,web)