Before I start, I'd like to say that I already tried the solution proposed in spring-boot-devtools reload of multi-module maven project changes, which didn't work for me.
Problem:
I have a multi-module Spring Boot project of this sort:
The module launcher has a Maven dependency on module GUI. I launch my Spring Boot application from the main method in launcher.
When I run the application and change any HTML file in GUI module, the spring-boot-devtools
dependency doesn't do a live reload of these changes for my running application. Not even manual restart of launcher helps. I need to compile GUI manually and then run launcher again.
What I tried:
- I tried defining the
spring-boot-devtools
dependency first in parentpom.xml
, then in GUI module only and then in both at the same time. - I tried adding
spring.devtools.restart.additional-paths=../gui
in myapplication.properties
file as suggested in spring-boot-devtools reload of multi-module maven project changes. This does indeed trigger the reload (according to the log), but those changes just don't propagate to thejar
file of GUI dependency. Also, before I even made this project into multi-module, there was no need for reloading just because of HTML files (nothing is being compiled) and I could see the changes right away.
I use Netbeans GUI if that's of any help. I also tried running the project from command line, with no success. The Maven packaging on all modules is set to jar
.
spring.devtools.restart.additional-paths=
with absolute paths? – ProvisoC:\\Users\\Saraph\\path\\to\\gui
. However I'd still want to generalize this somehow. While it works for my machine, every single team member would have to reconfigure this. – Workbook