IDEA中实现springboot热部署
IDEA中实现springboot热部署
·
IDEA中实现springboot热部署
热部署: 每一次修改代码后会自动更新,无需每次重启
依赖(pom.xml)
修改后记得Reload
一下
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-devtools</artifactId>
<scope>runtime</scope>
<optional>true</optional>
</dependency>
application.properties
# 热部署
spring.devtools.restart.enabled=true
settings
-
搜索
Compiler
,勾选Build project automatically
-
Advanced Settings
->勾选Allow auto-make to start even if developed application is currently running
加快热部署速度
现在SpringBoot就可以自动热部署了,效果还不错,但是感觉速度有点慢。settings
->Languages & Frameworks
->Spring
->Spring Boot
设置Refresh health in the Actuator tab ewver
为1

魔乐社区(Modelers.cn) 是一个中立、公益的人工智能社区,提供人工智能工具、模型、数据的托管、展示与应用协同服务,为人工智能开发及爱好者搭建开放的学习交流平台。社区通过理事会方式运作,由全产业链共同建设、共同运营、共同享有,推动国产AI生态繁荣发展。
更多推荐
所有评论(0)