设置Idea Ctrl+Alt+S 查找make project automatically --> 选中
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-devtools</artifactId>
<optional>true</optional>
<scope>true</scope>
</dependency>
<build>
<plugins>
<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
<configuration>
<fork>true</fork> //该配置必须
</configuration>
</plugin>
</plugins>
说明:
新建一个类与方法修改都能启动
原文:http://blog.51cto.com/357712148/2130113