Java Development issues Summary -4-maven usage issues Summary

Source: Internet
Author: User

Non-resolvable Parent POM
[INFO] Scanning for projects ... [ERROR] The build could not read 1 project---[Help 1][error]   [ERROR] the   project Com.iflytek.ossp:ossp-resserver-serv Ice:1.0.0-snapshot (C:\Users\moon\Desktop\ossp-resservice-maven\ossp-resserver-service\pom.xml) has 1 Error[error]     non-resolvable Parent Pom:could not find artifact Com.iflytek.ossp:ossp-resserver-all:pom:1.0.0-snapshot and ' Parent.relativepath ' points at wrong local POM @ line one, column, [Help 2][error] [ERROR]-See the full stack tr Ace of the errors, re-run Maven with THE-E switch. [ERROR] Re-run Maven using The-x switch to enable full debug logging. [ERROR] [ERROR] For more information on the errors and possible solutions, please read the following articles:[error] [Help 1] http://c Wiki.apache.org/confluence/display/maven/projectbuildingexception[error] [Help 2] http://cwiki.apache.org/ Confluence/display/maven/unresolvablemodelexception

The parent's Pom file could not be resolved, and it should be the use of inheritance in the Pom file.

<parent>        <groupId>com.iflytek.ossp</groupId>        <artifactid>ossp-resserver-all </artifactId>        <version>1.0.0-SNAPSHOT</version></parent>

Can try to join <relativePath>

<parent>        <groupId>com.iflytek.ossp</groupId>        <artifactid>ossp-resserver-all </artifactId>        <version>1.0.0-SNAPSHOT</version>        <relativepath> /ossp-resserver-all/pom.xml</relativepath></parent>

Unable to locate the Javac Compiler in
Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:2.3.2:compile (Default-compile) on project Ossp-resserver-service:compilation Failure[error] Unable to locate the Javac Compiler In:[error] C:\Java\jre6\. \lib\tools.jar[error] Ensure you is using JDK 1.4 or above and[error] not a JRE (the Com.sun.tools.javac.Main clas S is required). [ERROR] Cases you can change the location of your java[error] installation by setting the Java_home environment variable.[ ERROR], [Help 1][error] [ERROR]-See the full stack trace of the errors, re-run Maven with THE-E switch. [ERROR] Re-run Maven using The-x switch to enable full debug logging. [ERROR] [ERROR] For more information on the errors and possible solutions, please read the following articles:[error] [Help 1] http://c Wiki.apache.org/confluence/display/maven/mojofailureexception

A similar error should be a JRE configuration issue:

Right-click the project->java buid path->libraries->jre->edit->install JRES...->EDIT->JRE system libraries-> Add External JREs. , find the Missing Jar (Toos.jar) to add in.

No goals has been specified for this build.

The following error occurred when Maven BUiD:

[ERROR] No goals has been specified for this build. Must specify a valid lifecycle phase or a goal in the format <plugin-prefix>:<goal> or <plugin-group-id >:<plugin-artifact-id>[:<plugin-version>]:<goal>. Available lifecycle Phases Are:validate, Initialize, generate-sources, process-sources, Generate-resources, Process-resources, compile, process-classes, generate-test-sources, Process-test-sources, Generate-test-resources, Process-test-resources, Test-compile, process-test-classes, test, Prepare-package, package, Pre-integration-test, Integration-test, Post-integration-test, verify, install, deploy, Pre-clean, clean, Post-clean, Pre-site, site, Post-site, Site-deploy. "Help 1][error" [ERROR] to see the full stack trace of the errors, re-run Maven with THE-E switch. [ERROR] Re-run Maven using The-x switch to enable full debug logging. [ERROR] [ERROR] For more information about the errors and possible solutions, please read the following aRticles:[error] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/NoGoalSpecifiedException 

Because BUiD goal is not specified, the default value is added to the BUiD section in the Pom file.

<defaultGoal>compile</defaultGoal>

Publish a third-party jar package to a

1. First, modify the MAVEN configuration in Eclipse.

Do not use the inline default configuration.

The installation directory that points to maven.

2. Configuring Maven Setting.xml

<?xml version= "1.0" encoding= "UTF-8"? ><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://m Aven.apache.org/xsd/settings-1.0.0.xsd "> <pluginGroups> </pluginGroups> <proxies> </ proxies> <servers> <server> <id>nexus-releases</id> <username>admin</use rname> <password>123</password> </server> <server> <id>nexus-snapshots&lt ;/id> <username>admin</username> <password>123</password> </server> </se rvers> <mirrors> </mirrors> <profiles> <profile> <id>dev</id> <r Epositories> <repository> <id>local-nexus</id> <url>http://192.168.77. 214:9088/nexus/content/groups/public/</url> <releases> <enabled>true</enabled> </releases>      <snapshots> <enabled>true</enabled> </snapshots> </repository> </repositories> </profile> </profiles> <activeProfiles> <activeprofile>dev</ Activeprofile> </activeProfiles></settings>

3. Release third-party jar packages

Reproduced in this article, the original blog address is attached

Java Development issues Summary -4-maven usage issues Summary

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.