错误: 找不到或无法加载主类 com.mabang.WmsApiApplication

Posted Roam-G

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了错误: 找不到或无法加载主类 com.mabang.WmsApiApplication相关的知识,希望对你有一定的参考价值。

1.报错

 

按照网上教程

输入 mvn clean compile

 再次报错

[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time:  14.647 s
[INFO] Finished at: 2022-03-20T15:30:33+08:00
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal on project wms-api: Could not resolve dependencies for project com.mabang:wms-api:jar:0.0.1-SNAPSHOT: Failed to collect depen
dencies at com.tencent.cloud:cos-sts-java:jar:3.0.3: Failed to read artifact descriptor for com.tencent.cloud:cos-sts-java:jar:3.0.3: Could not transfer art
ifact com.tencent.cloud:cos-sts-java:pom:3.0.3 from/to bintray-qcloud-maven-repo (https://dl.bintray.com/qcloud/maven-repo/): Failed to transfer file https:
//dl.bintray.com/qcloud/maven-repo/com/tencent/cloud/cos-sts-java/3.0.3/cos-sts-java-3.0.3.pom with status code 502 -> [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/DependencyResolutionException

 没有首先对父项目进行clean和install ,在父项目下有的子项目在首次运行clean和install前,应该先运行父项目的clean和install。

以上是关于错误: 找不到或无法加载主类 com.mabang.WmsApiApplication的主要内容,如果未能解决你的问题,请参考以下文章

如何解决Eclipse下“找不到或无法加载主类”的错误

错误: 找不到或无法加载主类 ArrayListMagnet?

手动启动tomcat错误: 找不到或无法加载主类

如何解决Eclipse下“找不到或无法加载主类”的错误

错误: 找不到或无法加载主类 Examplel

Java 错误:找不到或无法加载主类