I have a Spring Roo project and I use mvn jetty:run to run my app. The only problem is changes to the *.java classes do not hot deploy, while changes to *.jspx hot deploy fine.
So how can I configure mvn jetty to hotdeploy for java classes?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
You need to set the
scanIntervalSecondsto a value greater than 0 to enable it:So the configuration might looks like this:
Once enabled, the jetty maven plugin will scan the directory defined in
classDirecory(which points to${project.build.outputDirectory}by default i.e.target/classes) for changes.You then just need to have your IDE compile classes in
target/classes(or to runmvn compile) and Jetty will restart the context upon changes on Java classes.