spring-boot-devtools 是Spring为开发者提供的热加载工具包
在STS中,pom.xml文件内添加如下依赖即可:
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-devtools</artifactId>
<scope>runtime</scope>
<optional>true</optional>
</dependency>
此时 发现Maven更新后,依然缺失spring-boot-devtools jar包,如下图显示missing:
![](https://img-blog.csdnimg.cn/img_convert/6fb9ec7d35c58c6ea886af91897edc92.png)
解决办法如下:Maven更新项目时选择 Force Update 强制更新即可,如下图所示:
![](https://img-blog.csdnimg.cn/img_convert/3596b4a1e6c9dfc32c65416ca52a5f86.png)
![](https://img-blog.csdnimg.cn/img_convert/0d91335b9c301ae668049e7bfd6a5ea3.png)
踩坑笔记,以助后人。