SpringBoot打包异常提示:Unable to find a single main class from the following candidates
说明该项目中有很多main方法,需要制定一个main方法的入口。

在maven项目中加上这个,指定入口和启动类型

 <build><plugins><plugin><groupId>org.springframework.boot</groupId><artifactId>spring-boot-maven-plugin</artifactId><configuration><!-- 指定该Main Class为全局的唯一入口 --><mainClass>com.bsj.boyun.open.car.BoyunOpenCarApplication</mainClass><layout>ZIP</layout></configuration><executions><execution><goals><goal>repackage</goal><!--可以把依赖的包都打包到生成的Jar包中--></goals></execution></executions></plugin></plugins></build>

解决Unable to find a single main class from the following candidates相关推荐

  1. 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.Sam ...

  2. 【异常】Maven构建报错 repackage failed: Unable to find a single main class from the following candidates

    一.报错内容 Failed to execute goal org.springframework.boot: spring-boot-maven-plugin:2.6.11:repackage (r ...

  3. 异常处理(六)--------SpringBoot+Maven项目运行异常:Unable to find a single main class from the following candidat

    异常详情 Failed to execute goal org.springframework.boot:spring-boot-maven-plugin:1.4.2.RELEASE:run (def ...

  4. ubuntu14.04.5装cuda7.5记录(解决unable to locate the kernel source,装cuda黑屏问题,装cuda循环登录问题)

    ubuntu14.04.5装cuda7.5记录(解决unable to locate the kernel source,装cuda黑屏问题,装cuda循环登录问题) 参考文章: (1)ubuntu1 ...

  5. Windows下Python 3.6 + VS2017 + Anaconda 解决Unable to find vcvarsall.bat问题

    Windows下Python 3.6 + VS2017 + Anaconda 解决Unable to find vcvarsall.bat问题 参考文章: (1)Windows下Python 3.6 ...

  6. Sublime Text 解决 Unable to download XXX 问题

    Sublime Text 解决 Unable to download XXX 问题 参考文章: (1)Sublime Text 解决 Unable to download XXX 问题 (2)http ...

  7. 解决Unable to create group (name already exists)

    解决Unable to create group (name already exists) TF在保存模型tf.keras.models.Model.save(),出现ValueError: Una ...

  8. 解决eclipse maven工程中src/main/resources目录下创建的文件夹所显示样式不是文件夹,而是“包“图标样式的问题

    解决eclipse maven工程中src/main/resources目录下创建的文件夹所显示样式不是文件夹,而是"包"图标样式的问题 参考文章: (1)解决eclipse ma ...

  9. ZooKeeper只完美解决Unable to read additional data from server sessionid 0x0报错问题,并带你深度理解ZooKeeper内部机制之选举机制

    ZooKeeper只完美解决Unable to read additional data from server sessionid 0x0报错问题,并带你深度理解ZooKeeper内部机制之选举机制 ...

  10. 解决Unable to create new native thread

    转载:解决Unable to create new native thread 两种类型的Out of Memory java.lang.OutOfMemoryError: Java heap spa ...

最新文章

  1. 图像色彩空间与应用转换
  2. Hadoop安装配置,并使用Hadoop计算圆周率测试Hadoop是否安装成功
  3. 如何发现优秀的IT开发人员
  4. NR 5G RLC无线链路控制
  5. 数据中心机房供电需求有哪些?存在哪些电能质量问题?
  6. how to find the tomcat version info on linux
  7. html 高度不够,HTML/CSS:Div未扩展到内容高度
  8. 分布式架构在农业银行的应用实践与展望
  9. 网络管理与维护作业9
  10. oracle 查询脚本分析,一个oracle数据查询脚本
  11. ServletResponse的getOutputStream()与getWriter()使用冲突
  12. OpenShift应用镜像构建(4) - fabric8-maven-plugin
  13. c语言打印字符数据在屏幕上,在屏幕上输出各种类型的数据
  14. oracle日期时间函数
  15. iPhone屏幕尺寸和分辨率
  16. Android ndk开发C调用C++
  17. mc服务器文件夹改皮肤,我的世界皮肤放在哪个文件夹位置及更换方法解析
  18. (转)汇编bne的问题
  19. GDI+绘图基础,绘制表格
  20. AI 收藏夹 Vol.004:元宇宙走偶像路线了,虚拟爱豆出道

热门文章

  1. VGA , CVBS , HDMI 三者的区别
  2. bzoj4199品酒大会
  3. java裂变_微信现金红包单一红包、裂变红包(Java版)
  4. 计算机如何使用网络共享中心,电脑网络共享中心在哪
  5. 【报告分享】2020年K12在线教育行业广告策略用户调研报告(附下载)
  6. markdown温习笔记
  7. Unity-之-物体旋转-跳跃-2021.5.13
  8. mysql的tps是什么意思_Mysql数据库的QPS和TPS的意义和计算方法
  9. 看完《我的前半生》的些许感悟
  10. html弹性布局什么意思,弹性布局display:flex是什么意思