原文:SpringBoot學習之一 Unable to find a single main class from the following candidates

在啟動SpringBoot項目是報錯 Unable to find a single main class from the following candidates boot.myboot.SampleController, boot.myboot.App 意思 是從這兩個類中找不到要執行那個main方法 執行spring boot:run X打印出Debug日志 錯誤原因是因為:在這兩個類中都 ...

2017-11-08 22:20 0 1167 推薦指數:

查看詳情

解決SpringBoot項目repackage failed: Unable to find main class Maven打包問題

最近在開發中,遇到這樣一個問題,一個通用的工具類項目,在進行打包時,出現repackage failed: Unable to find main class提示找不到主類問題,我就想,我這個項目是一個通用的工具類,不是一個SpringBoot Web工程,我又不需要Main方法的程序啟動入口 ...

Wed May 08 20:53:00 CST 2019 0 1250
maven打包出現unable to find main class問題

搜了好久,有人提到需要spring-boot-maven-plugin這個插件。 添加以后,有的可以了,有的不行。 最后發現是插件必須配置<skip>true</skip>這個 ...

Wed Aug 05 02:00:00 CST 2020 0 1286
Could not find the main class

  最近開發了一個短信報警的服務,打成程序包之后,再本地windows啟動(start.bat)沒有問題,但是發到生產環境,報如下錯: Could not find the main class 莫名其妙的報錯,網上查了一下,都無法解決,后來想到既然我本地是正常的,那很有可能是環境問題 ...

Tue May 19 17:37:00 CST 2020 0 1892
 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM