2
votes

I am using Grails 1.3.4. Using grails WAR command, I build the war and deploy it to Tomcat 6.0.20. When tomcat is started, the war gets exploded and application works fine as required.

The questions, if I make any changes to say for example a .js file in the exploded war package , the change never gets reflected in the front end even after restarting tomcat. It is the same case for .gsp pages. So every time I have to build the war again (including my changes) and redeploy it again.

Is there anything I am missing or something I am doing wrong?

Cheers! jAY

2
Is there a specific reason you need to test the changes in tomcat rather than in the built-in grails dev environment? What you're trying to solve is essentially what Grails' development environment is for.Rob Hruska
Well, the reason I asked was because during a scenario, after the war had been deployed to war (I wanted to make changes to a GSP page to check for a value (just to check)). But as I said, the GSP did not refresh. So I thought I would ask the experts for the solution. Wanted to know how it could be achieved. :)Jay Chandran

2 Answers

2
votes

This is slightly related to Modifying groovy code at runtime in grails application

For GSP at least you can set grails.gsp.enable.reload=true But if you it more often you will eventually get OutOfMemory exception. So be careful with that.

0
votes

are you deleting the war file before restarting the application server? If not tomcat will just explode it again and it will over write your changes