一、SpringBoot项目打包后的jar包非常小,只有4KB?
1.1、解决方法
pom.xml中添加如下配置
<build>
<plugins>
<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
<!-- 此处的版本根据实际情况自己调整 -->
<version>2.6.13</version>
<configuration>
<addResources>true</addResources>
</configuration>
<executions>
<execution>
<goals>
<goal>repackage</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>