IDEA中实现springboot热部署

IDEA中实现springboot热部署

热部署: 每一次修改代码后会自动更新,无需每次重启

依赖(pom.xml)

修改后记得Reload一下

xml 复制代码
<dependency>
    <groupId>org.springframework.boot</groupId>
    <artifactId>spring-boot-devtools</artifactId>
    <scope>runtime</scope>
    <optional>true</optional>
</dependency>

application.properties

java 复制代码
# 热部署
spring.devtools.restart.enabled=true

settings

  1. 搜索Compiler,勾选 Build project automatically

  2. 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

相关推荐
一 乐12 分钟前
家政服务管理系统|基于springboot + vue家政服务管理系统(源码+数据库+文档)
java·数据库·vue.js·spring boot·论文·毕设·家政服务管理系统
碳基硅坊1 小时前
Spring AI:把大模型接进 Spring 应用
java·人工智能·spring ai
黄毛火烧雪下1 小时前
Java 核心知识点总结(一)
java·开发语言
技术小结-李爽2 小时前
【工具】Maven的下载、安装、使用
java·maven
极创信息2 小时前
Linux挖矿病毒深度清理实战教程,从进程隐藏、Rootkit驻留到彻底根除
java·大数据·linux·运维·安全·tomcat·健康医疗
努力成为AK大王2 小时前
并发编程的核心挑战、优化方案与核心知识点总结
java·开发语言·数据库
云烟成雨TD2 小时前
Agent Scope Java 2.x 系列【10】技能(Skill)
java·人工智能·agent
摇滚侠2 小时前
SpringMVC 入门到实战 DispatcherServlet 源码解读 92-95
java·后端·spring·maven·intellij-idea
键盘歌唱家3 小时前
Spring AI 入门分享:它和“直接调 API“到底差在哪
java·人工智能·spring
宸丶一3 小时前
Day 10:LangGraph - Agent 的图执行引擎
java·windows·python