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-service: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 11, column 10 -> [Help 2]
[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/ProjectBuildingException
[ERROR] [Help 2] http://cwiki.apache.org/confluence/display/MAVEN/UnresolvableModelException

无法解析父级的POM文件,应该是是POM文件中使用了继承。

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

可以尝试加入<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] Please ensure you are using JDK 1.4 or above and
[ERROR] not a JRE (the com.sun.tools.javac.Main class is required).
[ERROR] In most cases you can change the location of your Java
[ERROR] installation by setting the JAVA_HOME environment variable.
[ERROR] -> [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/MojoFailureException

出现类似的错误应该是Jre配置问题:

右击项目->Java Buid Path->Libraries->JRE->Edit->Install JREs...->Edit->JRE system libraries->Add External JREs..->找到缺少的jar(toos.jar)添加进去。

No goals have been specified for this build.

Maven Buid时出现下面这个错误:

[ERROR] No goals have been specified for this build. You 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

是因为没有指定buid goal,在POM文件中的buid节中加入默认值就行了。

<defaultGoal>compile</defaultGoal>

将第三方jar包发布到私服

1、首先要修改eclipse中的Maven配置。

不要使用内嵌的默认配置。

指向Maven的安装目录。

2、配置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://maven.apache.org/xsd/settings-1.0.0.xsd">
<pluginGroups>
</pluginGroups>
<proxies>
</proxies>
<servers>
<server>
<id>nexus-releases</id>
<username>admin</username>
<password>123</password>
</server>
<server>
<id>nexus-snapshots</id>
<username>admin</username>
<password>123</password>
</server>
</servers>
<mirrors>
</mirrors> <profiles>
<profile>
<id>dev</id>
<repositories>
<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、发布第三方jar包

Eclipse初次java开发问题总结-4-Maven使用问题汇总的更多相关文章

  1. Eclipse初次java开发问题总结-3

    上篇中提到解决的一个问题是mysql驱动报的: com.mysql.jdbc.exceptions.jdbc4.CommunicationsException: Communications link ...

  2. Eclipse初次java开发问题总结-2

    今天对之前写的servlet程序做了个简单的性能测试发现了一些问题,经过解决这些问题没有再重现,有些问题自己确切知道原因,有的则不太确定. 1.配置文件读取问题 项目中使用.properties作为配 ...

  3. eclipse,myeclipse开发环境下,maven远程部署到tomcat7服务器(图文)

    有的人想在eclipse写java web 项目,通过maven也是一种实现的方法,可以实现java web 项目打包成war,发布到tomcat. 在pom.xml文件的build增加下面的代码,相 ...

  4. Jdk1.7+eclipse搭建Java开发环境

    Jdk1.7+eclipse搭建Java开发环境 1.    下载jdk1.7 http://www.oracle.com/technetwork/java/javase/downloads/jdk7 ...

  5. Eclipse For Java开发环境部署

    Eclipse For Java开发环境部署 1.准备工作 jdk安装包 jdk官网下载 Eclipse安装包 Eclipse官网下载 Eclipse下载时选择图中所示的国内镜像地址下载 下载后的文件 ...

  6. Java开发环境配置(4)--Maven安装 环境变量配置,本地仓库配置---插件安装

    说明在前:本人用过的 luna  mars 等,都已经自带maven插件的了,以下有些文章是很老的,讲到maven插件的安装都可以忽略掉. maven安装eclipse在线配置maven搞定所有插件_ ...

  7. linux下的Java开发 intellij idea+tomcat+maven

    前期准备:安装intellij idea.下载tomcat.下载maven(注意我用的是tomcat6.maven 3.2.1.jdk1.6.0_45,之前maven用的3.5结果报错,搞了好久,建议 ...

  8. Java开发学习(三十)----Maven聚合和继承解析

    一.聚合 分模块开发后,需要将这四个项目都安装到本地仓库,目前我们只能通过项目Maven面板的install来安装,并且需要安装四个,如果我们的项目足够多,那么一个个安装起来还是比较麻烦的 如果四个项 ...

  9. Java开发学习(三十一)----Maven属性与版本管理

    一.属性 1.1 问题分析 如下图所示 你会发现,如果现在想更新Spring的版本,你会发现依然需要更新多个jar包的版本,这样的话还是有可能出现漏改导致程序出问题,而且改起来也是比较麻烦. 问题清楚 ...

随机推荐

  1. FFmpeg(1)-创建支持FFmpeg的AS项目

    一.新建Android Studio项目 注意点: 1.在“Create Android Project”栏目时,须勾选“Include C++ support” 复选框: 2.在“Customize ...

  2. CCZone

    /**************************************************************************** Copyright (c) 2010 coc ...

  3. Zend Studio 12 windows 无限期试用

    安装: 1.下载最新版本Zend Studio:http://downloads.zend.com/studio-eclipse/12.0.0/ZendStudio-12.0.0-win32.win3 ...

  4. Solr实现 并集式、多值、复杂 过滤查询的权限【转】

    公司开发使用的搜索引擎核心是Solr,但是应为业务原因,需要相对复杂权限机制. 1)通过Solr的filterQuery可以实现field过滤,实现过滤项的效果.索引A{filter1:a,field ...

  5. js如何获取前后连续n天的时间

    function GetDateStr(AddDayCount) { var dd = new Date(); dd.setDate(dd.getDate()+AddDayCount);//获取Add ...

  6. Beginning SDL 2.0(3) SDL介绍及BMP渲染

    SDL是一个跨平台的多媒体库.为了实现跨平台,SDL提供了一个简单的界面库抽象,比如提供了SDL_Window用于表示窗口句柄,SDL_Surface.SDL_Texture.SDL_Renderer ...

  7. django model form 保存方法 django-rest-framework save 修改某一项值 方法

    django Model Form django-rest-framework save 方法 修改某个数据的值

  8. Linux各个文件夹的作用~~~非常实用!!

    linux下的文件结构,看看每个文件夹都是干吗用的/bin   二进制可执行命令 /dev 设备特殊文件 /etc 系统管理和配置文件 /etc/rc.d 启动的配置文件和脚本 /home 用户主目录 ...

  9. 基于jQuery左右滑动切换特效

    分享一款基于脚jQuery左右滑动切换特效.这是一款鼠标点击左右箭头按钮图片滚动切换,鼠标移到图片上显示透明边框特效.效果图如下: 在线预览   源码下载 实现的代码. html代码: <div ...

  10. golang深度获取子节点

    起因 需要在树形结构里获取子树,树形结构一般是存储一维数组,数组元素里存储子节点的指针 代码 package main import ( "errors" "fmt&qu ...