SpringBoot热部署

1、pom插件

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

2、maven依赖

<dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-devtools</artifactId>
<!--            <version>2.4.2</version>-->
            <scope>runtime</scope>
            <optional>true</optional>
        </dependency>

3、Perference

4、更新热键

5、重启Idea

原文地址:https://www.cnblogs.com/xidianzxm/p/14336648.html