项目中打断点不生效
在进行springboot项目开发过程中遇到进行打断点时不生效问题,断点显示红色却不打勾
如图
解决方法
在pomxml中进行修改
原先spring-boot-maven-plugin中是这样的
热部署也有可能影响,需要把<optional>true</optional>
设置成true
需要把<fork>false</fork>
设置成false,因为默认是true
修改后
代码
<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
<configuration>
<fork>false</fork>
<!-- spring-boot:run 控制台中文乱码解决 -->
<jvmArguments>-Dfile.encoding=UTF-8</jvmArguments>
</configuration>
</plugin>
解决