Eclipse creates web with maven error: Could not resolve archetype Org.apache.maven.archetypes:maven-archetype-webap__web

Source: Internet
Author: User
Tags aliyun

Problem Description:

Create a Web project times by using the Maven plug-in from Eclipse:

Could not resolve archetype org.apache.maven.archetypes:maven-archetype-webapp:release from any of the configured Repositories.
Could not resolve artifact Org.apache.maven.archetypes:maven-archetype-webapp:pom:release
Failed to resolve version of Org.apache.maven.archetypes:maven-archetype-webapp:pom:release:could not find metadata Org.apache.maven.archetypes:maven-archetype-webapp/maven-metadata.xml in local (C:\Users\liujunguang\.m2\ Repository
Failed to resolve version of Org.apache.maven.archetypes:maven-archetype-webapp:pom:release:could not find metadata Org.apache.maven.archetypes:maven-archetype-webapp/maven-metadata.xml in local (C:\Users\liujunguang\.m2\ Repository

Error Figure:




Solution:

to add a new catalog configuration in the Eclipse MAVEN configuration: Http://repo1.maven.org/maven2/archetype-catalog.xml
can also be downloaded to the local, and then added, this is faster, eclipse networking is relatively slow

As shown in figure:



Next, create a Web project using the catalog you just added

This is the time to see the Eclipse networking download:


This time to see if the creation was successful


If you still cannot create or the problem is not resolved you can install the following method:

1. Delete the file path that Maven has downloaded:. m2\repository\org\apache\maven

Delete and then try again, this time if you see progress, just have to wait patiently on the line


2.Maven download jar slow can use domestic Ari like

The specific configuration file (Settings.xml) is as follows, placed under the. M2 folder,. M2 is generally located under the user directory

<settings xmlns= "http://maven.apache.org/SETTINGS/1.0.0" xmlns:xsi= "http://www.w3.org/2001/XMLSchema-instance "Xsi:schemalocation=" http://maven.apache.org/SETTINGS/1.0.0 http://maven.apache.org/xsd/settings-1.0 .0.xsd "> <!--this is configured Ali maven image--> <mirrors> <mirror> <id>aliyun</id> <nam E>aliyun</name> <url>http://maven.aliyun.com/nexus/content/groups/public/</url> < mirrorof>central</mirrorof> </mirror> </mirrors> <profiles> <profile> &LT;ID&G t;nexus</id> <repositories> <repository> <id>central</id> <url>http:/ /repo.maven.apache.org/maven2</url> <snapshots> <enabled>false</enabled> </snap shots> </repository> <repository> <id>ansj-repo</id> <name>ansj reposit Ory</name> <url>http://maven.nlpcn.org/</url> <snapshots> <enabled>false</enabled> &LT;/SNAPSHOTS&G
				T </repository> </repositories> </profile> </profiles> <activeProfiles> <activepr Ofile>nexus</activeprofile> </activeProfiles> </settings>


Related Article

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.