1、依赖
<dependencies>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-devtools</artifactId>
<optional>true</optional>
</dependency>
</dependencies>
2、更改设置:
3、按住组合键:“Shift+Ctrl+Alt+/” ,选择 “Registry” ,选中打勾 “compiler.automake.allow.when.app.running”
最后:
- 修改了java类的地方,使用Ctrl+Shift+F9进行热更新
- 静态页面/模板页面,使用Ctrl+F9进行热更新
以上步骤不知道有没有多余的地方,但是都设置的情况下肯定是可以热部署的