Spring Boot热部署(springloader)

使用方式一

在pom.xml文件添加依赖包:

<plugin>
                      <groupId>org.springframework.boot</groupId>
                      <artifactId>spring-boot-maven-plugin </artifactId>
                      <dependencies>  
                       <!--springloaded  hot deploy -->  
                       <dependency>  
                           <groupId>org.springframework</groupId>  
                           <artifactId>springloaded</artifactId>  
                           <version>1.2.7.RELEASE</version>
                       </dependency>  
                    </dependencies>  
                    <executions>  
                       <execution>  
                           <goals>  
                               <goal>repackage</goal>  
                           </goals>  
                           <configuration>  
                               <classifier>exec</classifier>  
                           </configuration>  
                       </execution>  
                       </executions>
                </plugin>

运行方法二

如果使用的run as – java application的话,那么还需要做一些处理。 把spring-loader-1.2.7.RELEASE.jar下载下来,放到项目的lib目录中,然后把IDEA的run参数里VM参数设置为: -javaagent:.\lib\springloaded-1.2.4.RELEASE.jar -noverify 然后启动就可以了,这样在run as的时候,也能进行热部署

视频地址:http://baidu.iqiyi.com/watch/01364273974728388232.html?&recFrom=site&list=1
博客:
https://www.cnblogs.com/a8457013/p/8065489.html
https://www.cnblogs.com/jiangbei/p/8439394.html
https://www.cnblogs.com/xiong233/p/6796847.html

Jar包下载工具地址:

jar 包下载

http://mvnrepository.com/
https://jar-download.com
http://www.mvnjar.com/

myeclipse导入外部jar包

https://jingyan.baidu.com/article/11c17a2c290124f446e39d0b.html

猜你喜欢

转载自www.cnblogs.com/shy1766IT/p/9025428.html