Eclipse loading MAVEN Engineering tip Pom.xml cannot parse

Source: Internet
Author: User

Create a MAVEN project on another machine, copy to native, import, pom.xml file error, prompt error is as follows

Multiple annotations found at the This line:-execution default-testresources of goal Org.apache.maven.plugins:  Maven-resources-plugin:2.4.3:testresources Failed:plugin org.apache.maven.plugins:maven-resources-plugin:2.4.3 Or one of its dependencies could is resolved:failed to collect dependencies for Org.apache.maven.plugins:maven-reso urces-plugin:jar:2.4.3 () (org.apache.maven.plugins:maven-resources-plugin:2.4.3:testresources: default-testresources:process-test-resources)-Plugin execution not covered by lifecycle configuration: Org.apache.maven.plugins:maven-compiler-plugin:2.3.2:compile (Execution:default-compile, Phase:compile)- Coreexception:could not get the value of parameter Compilerid for plugin execution default-compile:pluginresolutionexc Eption:plugin org.apache.maven.plugins:maven-compiler-plugin:2.3.2 or one of its dependencies could not be Resolved:fai Led to collect dependencies for org.apache.maven.plugins:maven-compiler-plugin:jar:2.3.2 (): ArtIfactdescriptorexception:failed to read artifact descriptor for org.apache.maven:maven-plugin-api:jar:2.0.6: Artifactresolutionexception:failure to transfer org.apache.maven:maven-plugin-api:pom:2.0.6 from/HTTP Repo1.maven.org/maven2 was cached in the local repository, resolution would not be reattempted until the update interval o F Central have elapsed or updates are forced. Original error:could not transfer artifact org.apache.maven:maven-plugin-api:pom:2.0.6 from/to Central (HTTP// REPO1.MAVEN.ORG/MAVEN2): null to HTTP://REPO1.MAVEN.ORG/MAVEN2/ORG/APACHE/MAVEN/MAVEN-PLUGIN-API/2.0.6/ Maven-plugin-api-2.0.6.pom-coreexception:could not get the value of parameter Compilerid for plugin execution default- TestCompile:PluginResolutionException:Plugin org.apache.maven.plugins:maven-compiler-plugin:2.3.2 or one of its Dependencies could not being resolved:failed to collect dependencies for Org.apache.maven.plugins:maven-compiler-plugin:ja r:2.3.2 (): artifactdescriptorexception:Failed to read artifact descriptor for org.apache.maven:maven-plugin-api:jar:2.0.6:artifactresolutionexception: Failure to transfer org.apache.maven:maven-plugin-api:pom:2.0.6 from Http://repo1.maven.org/maven2 is cached in the LOC  Al Repository, resolution is not being reattempted until the update interval of the central have elapsed or updates are forced. Original error:could not transfer artifact org.apache.maven:maven-plugin-api:pom:2.0.6 from/to Central (HTTP///REPO1.M AVEN.ORG/MAVEN2): null to http://repo1.maven.org/maven2/org/apache/maven/maven-plugin-api/2.0.6/maven-plugin- Api-2.0.6.pom-execution Default-resources of Goal org.apache.maven.plugins:maven-resources-plugin:2.4.3:resources Failed:plugin org.apache.maven.plugins:maven-resources-plugin:2.4.3 or one of its dependencies could not be RESOLVED:FA iled to collect dependencies for org.apache.maven.plugins:maven-resources-plugin:jar:2.4.3 () ( Org.apache.maven.plugins:maven-resources-plugin:2.4.3:resources:default-resources:process-resources)-Plugin execution not covered by lifecycle Configuration:org.apache.maven.plugins: Maven-compiler-plugin:2.3.2:testcompile (Execution:default-testcompile, Phase:test-compile)

The error message appears in the Project tab of the POM header, and the project label content is

<project xmlns= "http://maven.apache.org/POM/4.0.0" xmlns:xsi= "Http://www.w3.org/2001/XMLSchema-instance"
xsi:schemalocation= "http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd" >


Reason

This is due to a missing Maven-resources-plugin-2.4.3.jar file. This file is under {user.home}\.m2\repository\org\apache\maven\plugins\maven-resources-plugin\. {User.home} is the configuration path for MAVEN, usually my document, which is the local Repository inside Window-preferences-myeclipse-maven4myeclipse-user setting.


Solution Solutions

1. Add Maven-resources-plugin configuration to the Pom.xml file

<dependency><groupId></groupid><artifactid></artifactid><version></version></DEPENDENCY>      

2, run under the command line mvn install , if executed correctly should be in {user.home}\.m2\repository\org\apache\maven\plugins\maven-resources-plugin\ See the Maven-resources-plugin-2.4.3.jar file below

3. Refresh Project (right-click Project Selection Refresh Item)

4. Refresh Maven configuration, right-click project node, select Maven4myeclipse-update Project config

Eclipse loading MAVEN Engineering tip Pom.xml cannot parse

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.