版权声明:本文为博主原创文章,未经博主允许不得转载。 https://cloud.tencent.com/developer/article/1425535
本博客简要介绍一下SpringBoot在IDEA软件配置热部署
IDEA自动make配置
目的是开启IDEA自动make功能
File->Setting->Build,Execution,Deployment->Complier,勾选Build Project automatically,ps:我这里是IDEA2017版本,不同版本名称可能不一样
快捷键:Ctrl+Shift+A,然后输入Registry,找到compiler.automake.allow.when.app.running并勾选
SpringBoot maven配置
maven加上jar
<!-- 热部署-->
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-devtools</artifactId>
<optional>true</optional>
</dependency>
maven build插件配置,记得将fork配置为true
<!-- 开启热部署-->
<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
<configuration>
<fork>true</fork>
</configuration>
</plugin>
配置好之后,还是需要重启一下IDEA的,然后修改java文件还是配置文件都会自动重启的,注意:Chrome浏览器可能有缓存,可以去按F12关了
扫码关注腾讯云开发者
领取腾讯云代金券
Copyright © 2013 - 2025 Tencent Cloud. All Rights Reserved. 腾讯云 版权所有
深圳市腾讯计算机系统有限公司 ICP备案/许可证号:粤B2-20090059 深公网安备号 44030502008569
腾讯云计算(北京)有限责任公司 京ICP证150476号 | 京ICP备11018762号 | 京公网安备号11010802020287
Copyright © 2013 - 2025 Tencent Cloud.
All Rights Reserved. 腾讯云 版权所有