springBoot of hot deployment

Official address: https: //docs.spring.io/spring-boot/docs/2.1.0.BUILD-SNAPSHOT/reference/htmlsingle/#using-boot-devtools
core dependencies:

<dependency> 
  <groupId>org.springframework.boot</groupId> 
  <artifactId>spring-boot-devtools</artifactId> 
  <optional>true</optional> 
</dependency>

After addition depend, in which ide restarting the application, subsequent modifications may take effect immediately after

File is not hot deployment
. 1, / the META-INF / Maven, / the META-INF / Resources, / Resources, / static, / public, or / Templates
2, the specified file is not hot deploy spring.devtools.restart.exclude = static / **, public / **
. 3, triggered manually restart spring.devtools.restart.trigger-file = trigger.txt
  change the code does not restart, through a text to control

https://docs.spring.io/spring-boot/docs/2.1.0.BUILD-SNAPSHOT/reference/htmlsingle/#using-boot-devtools-restart-exclude

Precautions: Do not turn it on a production environment, if you start with java -jar, springBoot is not hot deployment

Guess you like

Origin www.cnblogs.com/sjzxxy/p/12593944.html