当前位置:网站首页>Solution of idea hot start failure

Solution of idea hot start failure

2022-06-27 00:44:00 Helpless small yard farmer

Hot start failure resolution

One : The Intranet environment solves the problem of hot start failure

When using eclipse When configuring hot start , Add... Directly jar And plug-ins , But use idea when , You need to modify the settings yourself .
** Be careful :** If you change a project , It is also possible that the hot start fails , Because idea Reset default settings , Just follow the following steps again .

1、 find Setting---->Compiler Set up ( You can also use shortcut keys :Ctrl+Alt+S), Check "Build project automatically"

2、 Click the shortcut key Alt+Ctrl+shift+a+/,( If it doesn't , Just click Alt+shift+a) choice Registry, Open the interface .

3、 Open the interface , Check compiler.automake.allow.when.app.running that will do , Without this option , Reset idea You can find it .

Here we are , The hot start failure has been resolved , You can restart it again idea.

Two : The Intranet environment solves the problem of hot start failure

1.pom Add spring-boot-devtools My bag ,optional You have to set true.

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

2. Add the hot deployment configuration to the project configuration file

#  Turn on hot deployment 
spring.devtools.restart.enabled=true
# Restart directory 
spring.devtools.restart.additional-paths=src/main/java
#classpath In the catalog templates Folder content modification does not restart 
spring.devtools.restart.exclude=templates/** 

3. modify spring-boot-maven-plugin plug-in unit

<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
<configuration>
<fork>true</fork>
</configuration>
</plugin>

If it still does not take effect, modify it according to the operating steps of the Intranet environment idea Configuration of .

原网站

版权声明
本文为[Helpless small yard farmer]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/178/202206262358443493.html