IntelliJ 15, SpringBoot devtools livereload not working

I am guessing you are coding and expect DevTools to auto-magically figure out you have changed something in your project? Devtools does that by watching your classpath folder(s). When a .class file (or a resource) has changed, devtools take the appopriate action.

If you don't see anything, that's probably because you're just coding and not updating the classpath. You have to invoke Make Project to update the classpath. See the documentation


In IntelliJ 2021.2 compiler.automake.allow.when.app.running option dissappeared. This option was moved to Advanced settings: enter image description here


if you use IntelliJ IDEA, adding the spring-boot-devtools is not enough. This is because unlike Eclipse, you need to explicitly tell IntelliJ IDEA to “Make The Project” for it to build to the target classpath.

see on youtube

The easiest solution: run app debug mode and press Ctrl + f9 (short-cut for build)

or

  1. You need to enable the “Make project automatically” option. You can find it in Settings – Build, Execution, Deployment – Compiler
  2. To open the registry, Press Ctrl-Alt-Shift-/ and select "Registry" from the menu that appears, enable the “compiler.automake.allow.when.app.running” check-box.

build-project-automatically

compiler-automake-allow-when-app-running


To solve this You can do like:

  1. Add LiveReload extension in your browser.
  2. Add devtools dependencies to your pom.xml(if it's maven (spring-boot-devtools)).
  3. In your intellij IDEA go to: file->settings->build,execution,deployment. Go to ->compiler->build project automatically.
  4. In your intellij IDEA: SHIFT+Ctrl+A ->registry-> compiler.automake.allow.when.app.running