一、现象描述
Spring boot启动时报错误如下:
Failed to execute goal org.springframework.boot:spring-boot-maven-plugin:1.4.1.RELEASE:run (default-cli) on project SpringBootHotDeploy: Execution default-cli of goal org.springframework.boot:spring-boot-maven-plugin:1.4.1.RELEASE:run failed: Unable to find a single main class from the following candidates [com.queen.controller.HotDeployAPP, com.queen.controller.APP] -> [Help 1]
从字面上理解就是无法从下列候选项中找到单个主类。这个问题笔者遇到时候比较懵逼,后来发现自己建了两个APP类,导致启动服务无法判断到底要启动哪一个APP类。

二、解决办法
解决方案很简单:删除一个你想要删除的APP就可以了
=======欢迎大家拍砖,小手一抖,多多点赞哟!=======
版权声明:本文为博主原创文章,允许转载,但转载必须标明出处。