我是靠谱客的博主 如意航空,最近开发中收集的这篇文章主要介绍Failed to execute goal org.codehaus.mojo:exec-maven-plugin:3.0.0:exec (default-cli)的解决方法,觉得挺不错的,现在分享给大家,希望可以做个参考。

概述

问题:
maven项目在没有任何问题的情况下,运行main主方法报下列错误
Failed to execute goal org.codehaus.mojo:exec-maven-plugin:3.0.0:exec (default-cli)

idea 2020.1版本
尝试网上很多方法,没有解决问题

最后删除本地仓库中的 org.codehaus.mojo整个文件夹,运行main方法自动下载插件

[INFO] Scanning for projects...
Downloading from alimaven: http://maven.aliyun.com/nexus/content/groups/public/org/codehaus/mojo/maven-metadata.xml
Downloaded from alimaven: http://maven.aliyun.com/nexus/content/groups/public/org/codehaus/mojo/maven-metadata.xml (21 kB at 16 kB/s)
Downloading from alimaven: http://maven.aliyun.com/nexus/content/groups/public/org/codehaus/mojo/exec-maven-plugin/maven-metadata.xml
Downloaded from alimaven: http://maven.aliyun.com/nexus/content/groups/public/org/codehaus/mojo/exec-maven-plugin/maven-metadata.xml (773 B at 1.7 kB/s)
Downloading from alimaven: http://maven.aliyun.com/nexus/content/groups/public/org/codehaus/mojo/exec-maven-plugin/3.0.0/exec-maven-plugin-3.0.0.pom
Downloaded from alimaven: http://maven.aliyun.com/nexus/content/groups/public/org/codehaus/mojo/exec-maven-plugin/3.0.0/exec-maven-plugin-3.0.0.pom (14 kB at 49 kB/s)
Downloading from alimaven: http://maven.aliyun.com/nexus/content/groups/public/org/codehaus/mojo/mojo-parent/50/mojo-parent-50.pom
Downloaded from alimaven: http://maven.aliyun.com/nexus/content/groups/public/org/codehaus/mojo/mojo-parent/50/mojo-parent-50.pom (34 kB at 105 kB/s)
Downloading from alimaven: http://maven.aliyun.com/nexus/content/groups/public/org/codehaus/mojo/exec-maven-plugin/3.0.0/exec-maven-plugin-3.0.0.jar
Downloaded from alimaven: http://maven.aliyun.com/nexus/content/groups/public/org/codehaus/mojo/exec-maven-plugin/3.0.0/exec-maven-plugin-3.0.0.jar (68 kB at 105 kB/s)
[INFO] 
[INFO] ------------------------------------------------------------------------
[INFO] Building ch04_hadoop 1.0-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO] 
[INFO] --- exec-maven-plugin:3.0.0:exec (default-cli) @ ch04_hadoop ---
  
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 6.560 s
[INFO] Finished at: 2020-12-17T09:53:51+08:00
[INFO] Final Memory: 18M/191M
[INFO] ------------------------------------------------------------------------

总结

猜测可能因为网络问题,插件下载不全

后续

程序main主方法可以正常运行,当程序代码错误时,job启动失败,也会报 org.codehaus.mojo插件问题,此时可以通过log4j日志定位错误信息修改代码在这里插入图片描述

最后

以上就是如意航空为你收集整理的Failed to execute goal org.codehaus.mojo:exec-maven-plugin:3.0.0:exec (default-cli)的解决方法的全部内容,希望文章能够帮你解决Failed to execute goal org.codehaus.mojo:exec-maven-plugin:3.0.0:exec (default-cli)的解决方法所遇到的程序开发问题。

如果觉得靠谱客网站的内容还不错,欢迎将靠谱客网站推荐给程序员好友。

本图文内容来源于网友提供,作为学习参考使用,或来自网络收集整理,版权属于原作者所有。
点赞(54)

评论列表共有 0 条评论

立即
投稿
返回
顶部