Home  >  Q&A  >  body text

spring boot + thymeleaf hot swap not working?

Every time you modify thymeleaf's templates, you need to restart spring boot. Although spring boot has a good startup speed, it is still very troublesome. Google has used spring-boot-devtools to achieve hot plugging.

Mypom.xml joined:

        <!-- hot swap -->
        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-devtools</artifactId>
            <version>1.3.0.RELEASE</version>
            <optional>true</optional>
        </dependency>

But this still has no effect, but I use mvn spring-boot:runAfter starting, after modifying thymeleaf's templates, I must restart to update the templates. At the same time, I have set Build project automatically in intellij-idea.

What is the reason why hot swapping is invalid?

我想大声告诉你我想大声告诉你2713 days ago620

reply all(1)I'll reply

  • 大家讲道理

    大家讲道理2017-05-17 10:00:57

    It may be thymeleaf’s cache and settingsspring.thymeleaf.cache=false

    reply
    0
  • Cancelreply