IDEA中Spring boot配置热部署

pom文件中添加

 1 <!-- 热部署 -->
 2 <dependency>
 3     <groupId>org.springframework.boot</groupId>
 4     <artifactId>spring-boot-devtools</artifactId>
 5     <optional>true</optional>
 6     <scope>true</scope>
 7 </dependency>
 8  ----------------------------------------------------
 9 <build>
10     <plugins>
11         <plugin>
12             <groupId>org.springframework.boot</groupId>
13             <artifactId>spring-boot-maven-plugin</artifactId>
14             <configuration>
15                 <!-- 没有该配置,devtools 不生效 -->
16                 <fork>true</fork>
17                 <addResources>true</addResources>
18             </configuration>
19         </plugin>
20     </plugins>
21 </build>

file-》settings-》build,execution,deployment-》Compiler

alt + shift + a 搜索 registry 选第一个

弹出框后下拉找到 compiler.automake.allow.when.app.running 勾选上即可

 

posted on 2018-05-22 16:16  Xiaox-xin  阅读(135)  评论(0编辑  收藏  举报

导航