Java 无法将project facet动态Web模块的版本更改为2.4

Java 无法将project facet动态Web模块的版本更改为2.4,java,spring,jsp,Java,Spring,Jsp,我尝试了stackflow为这个问题提供的所有解决方案,但是我面临同样的问题。我尝试将facet更改为3.0,但问题仍然是一样的 有谁能帮我一下吗 pom.xml http://maven.apache.org/maven-v4_0_0.xsd"> 4.0.0 安瓿 安瓿 战争 0.0.1-快照 AMPortal Maven网络应用程序 1.7 UTF-8 UTF-8 org.springframework 弹簧芯 4.1.4.1发布 org.springframework 弹簧网 4.1.

我尝试了stackflow为这个问题提供的所有解决方案,但是我面临同样的问题。我尝试将facet更改为3.0,但问题仍然是一样的 有谁能帮我一下吗

pom.xml http://maven.apache.org/maven-v4_0_0.xsd"> 4.0.0 安瓿 安瓿 战争 0.0.1-快照 AMPortal Maven网络应用程序


1.7
UTF-8
UTF-8
org.springframework
弹簧芯
4.1.4.1发布
org.springframework
弹簧网
4.1.4.1发布
org.springframework
SpringWebMVC
4.1.4.1发布
org.springframework
SpringJDBC
4.1.4.1发布
org.springframework.security
spring安全网
3.2.5.1发布
org.springframework.security
spring安全配置
3.2.5.1发布
朱尼特
朱尼特
3.8.1
测验
javax.servlet
jstl
1.2
javax.servlet
javax.servlet-api
3.1.0
假如
javax.servlet.jsp
jsp api
2.2
假如
mysql
mysql连接器java
5.1.34
org.apache.maven.plugins
maven编译器插件
3.1
1.6
1.6
安瓿
my web.xml

<web-app id="WebApp_ID" version="2.4"
xmlns="http://java.sun.com/xml/ns/j2ee"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee
http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd">

<display-name>Archetype Created Web Application</display-name>

<listener>
    <listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
</listener>


<!-- Loads Spring Security config file -->
<context-param>
    <param-name>contextConfigLocation</param-name>
    <param-value>        
        /WEB-INF/spring-security.xml,
        /WEB-INF/data-source-cfg.xml
    </param-value>
</context-param>


<!-- Spring MVC -->
<servlet>
    <servlet-name>mvc-dispatcher</servlet-name>

    <servlet-class>
        org.springframework.web.servlet.DispatcherServlet
    </servlet-class>

    <load-on-startup>1</load-on-startup>
</servlet>

<servlet-mapping>
    <servlet-name>mvc-dispatcher</servlet-name>
    <url-pattern>/</url-pattern>
</servlet-mapping>


<!-- Spring Security Filter -->
<filter>
    <filter-name>springSecurityFilterChain</filter-name>
    <filter-class>org.springframework.web.filter.DelegatingFilterProxy</filter-class>
</filter>

<filter-mapping>
    <filter-name>springSecurityFilterChain</filter-name>
    <url-pattern>/*</url-pattern>
</filter-mapping>

Web应用程序创建的原型
org.springframework.web.context.ContextLoaderListener
上下文配置位置
/WEB-INF/spring-security.xml,
/WEB-INF/data-source-cfg.xml
mvc调度器
org.springframework.web.servlet.DispatcherServlet
1.
mvc调度器
/
springSecurityFilterChain
org.springframework.web.filter.DelegatingFilterProxy
springSecurityFilterChain
/*

您的
web.xml中有以下标题

<web-app id="WebApp_ID" 
    version="2.4"
    xmlns="http://java.sun.com/xml/ns/j2ee"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd">

这基本上告诉您的容器(以及eclipse)这是一个2.4Servlet规范的应用程序

<web-app
    version="3.0"
    xmlns="http://java.sun.com/xml/ns/javaee"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd">

您的
web.xml中有以下标题

<web-app id="WebApp_ID" 
    version="2.4"
    xmlns="http://java.sun.com/xml/ns/j2ee"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd">

这基本上告诉您的容器(以及eclipse)这是一个2.4Servlet规范的应用程序

<web-app
    version="3.0"
    xmlns="http://java.sun.com/xml/ns/javaee"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd">


更改您的web.xml,它仍然是2.4版。您使用的是哪个版本的Java?更改您的web.xml,它仍然是2.4版。您使用的是哪个版本的Java?