如何使用intellij Idea实现项目的热加载?

工作开发中发现热加载非常重要,特别是启动分钟级的项目。非常影响开发效率。
以下是使用idea开启项目的热加载。

1、加入maven依赖:

<dependency>
        <groupId>org.springframework.boot</groupId>
        <artifactId>spring-boot-devtools</artifactId>
        <scope>runtime</scope>
</dependency>

2、打开setting–>Build,Execution,Deployment–>Compiler–>Build project automatically 打上勾。
在这里插入图片描述

3、按住 shift+alt+ctrl+/ ,并选择Registry
在这里插入图片描述

4、将下图选项勾上即可。
在这里插入图片描述

5、重新启动idea,设置生效。

附上热加载和热部署的区别:
https://blog.csdn.net/chao821/article/details/82703335

猜你喜欢

转载自blog.csdn.net/sinat_38535682/article/details/87532458