1、adding devtools to your project(微服务项目的pom)
<dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-devtools</artifactId> <scope>runtime</scope> <optional>true</optional> </dependency>
2、adding plugin to your pom(父类总工程的pom)
<plugins> <!--热部署需要导入--> <plugin> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-maven-plugin</artifactId> <version>2.2.2.RELEASE</version> <configuration> <fork>true</fork> <addResources>true</addResources> </configuration> </plugin> </plugins>
3、Enabling automatic build
(setting->build->Compiler->ADBC四个选项打√)
4、update the value of
(1)ctrl+shift+alt+/
(2)点击Registry
(3)把下图标注两个选项打√
5、重启idea