springboot热部署配置

时间:2023-03-08 16:27:25

1、pom添加spring-boot-devtools依赖和配置编译插件

<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-devtools</artifactId>
<optional>true</optional>
</dependency> <plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
</plugin>

2、配置IDEA

springboot热部署配置

Shift+Ctrl+Alt+/,选择Registry, 找到该选项,打勾

springboot热部署配置

3、重启项目