Issue
I'm developing using IntelliJ 11u on a spring mvc application using tomcat.
I tried the maven jetty plugin, but after a few builds I keep getting java permGen issues and then it just hangs. I was told this was because spring uses log4j and it has some sort of leaks?
Anyhow, I'm asking for tips to help fire up a server, tomcat, with my updated code so I can make quick updates and have tomcat reloaded.
Here are my current annoyances with tomcat:
Only code changes seem to get auto-reloaded, if I make changes to my view pages things don't get updated unless I redeploy. The maven jetty plugin seems to map to my view pages directly and I saw updates to my view pages instantly w/o it even redeploying.
if I have more than 1 thing running in intelliJ, like say I have a main program that I run, or a unit test, IntelliJ seems to re-order what gets run in the run drop down menu and also the shortcut keys get changed to the last thing I ran.
I use google chrome, for some reason when I start tomcat it brings firefox to the forefront and opens a new tab each and every time.
If someone can address any or all of the above issues that would be great as I hate this dance I have to go through just to update/redeploy my application. I wish it could just be a consitant method, using shortcuts or automatically without me having to close the tab created in firefox, and then minimizie it, or redploy for a simple view change etc.
Solution
You should configure IDEA to update classes and resources and enable a checkbox in the Run configuration to do it automatically on frame deactivation.
Browser can be changed in IDEA settings and you can disable opening browser at all in Tomcat Run/Debug configuration.
As for the Run panel tabs order, you can pin tabs using the tab right click menu, in this case they will remain in the Run or Debug panel in the order they were created.
Answered By - CrazyCoder
Answer Checked By - David Marino (JavaFixing Volunteer)