当前位置:   article > 正文

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.3.0:exec (defau

问题:
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] ------------------------------------------------------------------------

  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
  • 8
  • 9
  • 10
  • 11
  • 12
  • 13
  • 14
  • 15
  • 16
  • 17
  • 18
  • 19
  • 20
  • 21
  • 22
  • 23
  • 24
  • 25
  • 26

总结

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

后续

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

声明:本文内容由网友自发贡献,不代表【wpsshop博客】立场,版权归原作者所有,本站不承担相应法律责任。如您发现有侵权的内容,请联系我们。转载请注明出处:https://www.wpsshop.cn/w/小惠珠哦/article/detail/969572
推荐阅读
相关标签
  

闽ICP备14008679号