quarkus: Live reload doesn't work for kotlin, gradle kotlin dsl project
Describe the bug
i always have to restart the app whenever there’s a change
Expected behavior
No response
Actual behavior
No response
How to Reproduce?
No response
Output of uname -a or ver
No response
Output of java -version
No response
Quarkus version or git rev
No response
Build tool (ie. output of mvnw --version or gradlew --version)
No response
Additional information
No response
About this issue
- Original URL
- State: open
- Created 8 months ago
- Reactions: 1
- Comments: 18 (5 by maintainers)
But the general problem is indeed that when we detect a change, we are not correctly passing the necessary configuration to the Kotlin compiler.
While I think this is a good workaround, I don’t think this is a satisfying overall fix because it requires a lot of manual configuration. I believe the problem is still Quarkus not passing the same arguments that the regular compiler gets to the dev compiler.
After a long fight with the kotlin compiler options, gradle and the quarkus-gradle-plugin i finally found a workaround, not pretty but it works:
Helpful links:
Hope this will be fixed soon, we are migrating all our quarkus projects to Gradle and this issue sounds that it will cause additional problems.
demo.zip
You can:
curl localhost:8080/helloRestResponse.ok("a")toRestResponse.ok("b")curl localhost:8080/helloagain, which should crash the app.Let me know if this helps.