1、加maven依赖

        <dependency>
            <!--Spring 官方提供的热部署插件 -->
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-devtools</artifactId>
            <optional>true</optional>
        </dependency>

2、开启热部署

            <plugin>
                <groupId>org.springframework.boot</groupId>
                <artifactId>spring-boot-maven-plugin</artifactId>
                <configuration>
                    <fork>true</fork>
                </configuration>
            </plugin>

3、开启idea自动make功能 

  CTRL + SHIFT + A --> 查找make project automatically --> 选中 
  CTRL + SHIFT + A --> 查找Registry --> 找到并勾选compiler.automake.allow.when.app.running 

最后重启idea 

相关文章:

  • 2021-06-29
  • 2021-05-23
  • 2021-07-24
  • 2022-01-12
  • 2021-07-22
  • 2022-01-04
  • 2021-06-13
猜你喜欢
  • 2021-11-25
  • 2021-11-26
  • 2021-04-15
  • 2021-11-27
  • 2022-02-23
  • 2021-08-19
相关资源
相似解决方案