-
-
Notifications
You must be signed in to change notification settings - Fork 4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
gradle-build spring-boot devtools hot-reload not working because of hibernate annotation-processor #27744
Comments
Somehow this rings a bell. I thought it was fixed (long ago) but obviously not. |
Hi @atomfrede , |
Can you try with plain gradle? So two terninals, one running |
FYI, I've confirmed that the auto-reload works fine when using gradle directly (1 "bootrun" terminal + 1 "compileJava -t" terminal) |
in the jhipster's build based on gradle, when working on Intellij IDE, the hot-reload functionality provided by spring-boot-devtools fails because of hibernate annotation-processor. During the auto-make/build compilation, the compiler throws error "Problem with Filer: Attempt to recreate a file for type com.example.accessingdatarest.domain.User_" which aborts the re-compilation.
The problem can be reproduced in a much smaller scale project by using the "Accessing JPA Data with REST" spring sample project and then adding spring-boot devtools and hibernate annotation-process to the build-gradle file as shown below:
Error message thrown by the compiler is shown below (for Intellij, this shows up in the "auto-build" window):
Note1: the project will still automatically restart but code-changes are not recompiled
Note2: if I remove the hibernate annotation-processor (from the spring sample project), the hot-reload works as expected.
Does anyone have a work-around ?
Side-Note1: I'm a bit confused for why no-one else reported the same issue.
Side-Note2: I have the same problem on different OS (windows & ubuntu), different jdks (17 & 21) and different versions of gradle (8.7 & 8.10)
The text was updated successfully, but these errors were encountered: