Loading

springboot配置devtools热部署

需要引入该依赖

        <!--热部署-->
        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-devtools</artifactId>
            <scope>runtime</scope>
            <optional>true</optional>
        </dependency>

父工程的pom.xml引入

    <build>
        <plugins>
            <!--配置热部署需要该配置-->
            <plugin>
                <groupId>org.springframework.boot</groupId>
                <artifactId>spring-boot-dependencies</artifactId>
                <configuration>
                    <fork>true</fork>
                    <addResources>true</addResources>
                </configuration>
            </plugin>
        </plugins>
    </build>

在setting里面的勾上图上框的选项

update the value of

勾上自动编译

posted @ 2022-07-03 15:08  Rzk  阅读(79)  评论(0编辑  收藏  举报