问题:

1.新建项目后会提示一个这样的错

maven-compiler-plugin:3.1:compile(1 errors)

maven-compiler-plugin:3.1:testCompile(1 errors)

2.关掉后看pom.xml

3.plugin标签也报错,无法解析

鼠标放红叉上提示

错误:

 CoreException: Could not calculate build plan: Plugin org.apache.maven.plugins:maven-compiler-plugin:3.1 or one of its dependencies could not be resolved: Failed to read artifact 
 descriptor for org.apache.maven.plugins:maven-compiler-plugin:jar:3.1: UnresolvableModelException: Failure to transfer org.apache.maven:maven-parent:pom:23 from http://maven.aliyun.com/
 nexus/content/groups/public/ was cached in the local repository, resolution will not be reattempted until the update interval of alimaven has elapsed or updates are forced. Original error: Could 
 not transfer artifact org.apache.maven:maven-parent:pom:23 from/to alimaven (http://maven.aliyun.com/nexus/content/groups/public/): sun.security.validator.ValidatorException: PKIX path 
 building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target
- Plugin execution not covered by lifecycle configuration: org.apache.maven.plugins:maven-compiler-plugin:3.1:testCompile (execution: default-testCompile, phase: test-compile)
- Plugin execution not covered by lifecycle configuration: org.apache.maven.plugins:maven-compiler-plugin:3.1:compile (execution: default-compile, phase: compile) 

解决:

排查eclipse配置maven的地方,和配置的仓库都没问题

再排查settings.xml,可以尝试更换镜像的配置,但我不是这个问题(可以换成下面这个,是我成功后的)

 <mirrors>
<mirror>
<id>nexus-aliyun</id>
<mirrorOf>*</mirrorOf>
<name>Nexus aliyun</name>
<url>http://maven.aliyun.com/nexus/content/groups/public</url>
</mirror>
</mirrors>

因为错误是说解析不了plugin,我猜想是上次更新时强制关闭eclipse导致某些包没更新好,然后导致版本问题之类的总之无法解析出来报错,就重新换了一个仓库,就成功了

我认为应该是你自己的maven仓库里\org\apache\maven目录下的一些关于plugin的包受损了 ,也可以尝试只更换别人好的maven文件夹,或者全部删掉plugin的相关包重新下载

eclipse新建maven项目出错 pom.xml报错的更多相关文章

  1. 新建maven工程时pom.xml报错

    新建maven工程时,pom.xml报错:第一行报如下错误:multiple annotations found at this line后添加org.eclipse.m2e相关的plugin配置后, ...

  2. 创建maven项目时pom.xml报错的解决方法

    创建maven项目时pom.xml时: 出现如下报错信息: Failure to transfer commons-lang:commons-lang:jar:2.1 from https://rep ...

  3. 新建Maven工程,pom.xml报错web.xml is missing and <failOnMissingWebXml> is set to true

    错误原因: 项目中没有web.xml 解决办法: 在项目中添加web.xml 在pom.xml中添加下面的插件 <build> <plugins> <plugin> ...

  4. eclipse 创建maven 项目 动态web工程报错

    Eclipse 创建maven 项目 动态web工程 注:Eclipse版本为(Version: Mars.1 Release (4.5.1))maven版本为(apache-maven-3.3.9) ...

  5. Springboot项目中Pom.xml报错

    摘要:使用idea,两次在maven上浪费时间,第一次不知道怎么就解决了,第二次记录一下解决办法 参考博客地址: https://blog.csdn.net/u013129944/article/de ...

  6. maven项目建立pom.xml报无法解析org.apache.maven.plugins:maven-resources-plugin:2.4.3

    一.发现问题 建立maven项目后,pom.xml在显示红叉.鼠标放上去,显示Executiondefault-testResources of goalorg.apache.maven.plugin ...

  7. 新建maven项目index.jsp文件报错处理

    最近用eclipse新建了一个maven项目,结果刚新建完成index.jsp页面就报错了,先把错误信息贴出来看看 后来就找资料,结果发现两种解决办法,希望可以帮助用得上的人! 第一种:直接在pom. ...

  8. Eclipse导入Maven项目,使用server 启动报错,class 找不到,

    问题发现: 1.导入maven 项目后,用server 启动,选择项中没有这个项目 解决: 说明server 没有把该项目当成web项目,需要设置 项目右键 properties  ---- proj ...

  9. 新建Maven项目Index.jsp文件报错解决方法

    The superclass "javax.servlet.http.HttpServlet" was not found on the Java Build Path    in ...

随机推荐

  1. HBase构架原理

    HBase的概念: HBase在生态圈位置 HBase与HDFS对比 HBase与关系型数据库的比较 HBase表的特点: 4)任意模式:每一行都有一个可排序的主键和任意多的列,列可以根据自己的需要动 ...

  2. LA 3263 That Nice Euler Circuit(欧拉定理)

    That Nice Euler Circuit Little Joey invented a scrabble machine that he called Euler, after the grea ...

  3. [POJ3694]Network(Tarjan,LCA)

    [POJ3694]Network Description A network administrator manages a large network. The network consists o ...

  4. GDB学习笔记

    GDB是UNIX及UNIX-like下的调试工具.GDB这个调试工具相比于VC.z的优点是具有修复网络断点以及恢复链接等功能. 一.功能 一般来说,GDB主要帮助你完成下面四个方面的功能: 1.启动你 ...

  5. 为什么需要bootloader

    本文链接:https://blog.csdn.net/u012351051/article/details/50557899 受单片机和ARM7等小型CPU设备编程思维的影响,开始对嵌入式linux和 ...

  6. 命令行界面CLI

    1.hive   -e --执行一个或多个查询 hive -e "select * from student limit 3" 2. hive -e     > 将临时查询保 ...

  7. JAVA四种引用方式

    JAVA四种引用方式: java.lang.ref: 强引用(直接变量赋值) 软引用(SoftReference): 只有在要发生OOM错误之前才会回收掉老的软引用对象,应用场景主要防止内存溢出.(缓 ...

  8. orm中 如何模糊匹配某一年的用户和某一事时间段的用户

    导入Q查询

  9. python学习笔记(十八)python操作excel

    python操作excel需要安装通过pip安装xlwt, xlrd这两个模块: pip install xlwt pip insall xlrd 操作excel ,写入excel: import x ...

  10. [luogu]P1133 教主的花园[DP]

    [luogu]P1133 教主的花园 ——!x^n+y^n=z^n 题目描述 教主有着一个环形的花园,他想在花园周围均匀地种上n棵树,但是教主花园的土壤很特别,每个位置适合种的树都不一样,一些树可能会 ...