Workaround maven cannot upgrade to Web 3.0 and JDK versions due to update rollback errors

Source: Internet
Author: User

The first problem is resolved because the version number does not match the configuration file, and the workaround is to the. Setting directory under the project, modifying the version number in the Org.eclipse.wst.common.project.facet.core.xml file, such as:

Also modify the version of Web. xml

2.3:<! DOCTYPE Web-app Public "-//sun Microsystems, INC.//DTD Web Application 2.3//en" "Http://java.sun.com/dtd/web-app_2_3. DTD ">

2.4:<web-app id="Webapp_9" 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" >

2.5:< Web-app xmlns=<a target=" _blank " href=" http://java.sun.com/xml/ns/ Java ee ">http://java.sun.com/xml/ns/javaee</a>    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_2_5.xsd "   version="2.5">

3.0 : <WEB-APP&NBSP; version= span class= "attribute" style= "margin:0px; padding:0px ">xmlns=" http://java.sun.com/xml/ns/ Java ee "  xmlns:xsi=" http://www.w3.org/2001/XMLSchema-instance "&NBSP;

        xsi:schemalocation="/HTTP/ Java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd ">&NBSP;&NBSP;

3.1:<web-app xmlns:xsi= "http://www.w3.org/2001/XMLSchema-instance" xsi:schemalocation= "/http Xmlns.jcp.org/xml/ns/javaee http://xmlns.jcp.org/xml/ns/javaee/web-app_3_1.xsd " version=" 3.1 "xmlns= "Http://xmlns.jcp.org/xml/ns/javaee" >

The final JDK version also corresponds, so a second problem may occur.


The second issue is the configuration file resolution, which adds the following configuration to the Pom.xml file <build> directory <plugins>


This will solve the above two problems


Don't ask me who I am, please call me red scarf


Copyright NOTICE: This article for Bo Master original article, without Bo Master permission not reproduced.

Workaround maven cannot upgrade to Web 3.0 and JDK versions due to update rollback errors

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.