Reputation: 65
I have a war file running with tomcat on a server with java 1.6. I need to update the java version on the server and have the war file use java 1.7. Will this happen automatically when I restart tomcat, or does the war file need to be recompiled?
I am attempting to reproduce an error in our production environment (1.7) that does not happen in our QA environment (1.6). Here is the issue if interested.
Upvotes: 0
Views: 3062
Reputation: 7396
The WAR is not a stand-alone program. It will use whatever version of Java you are running Tomcat with. You can't have Tomcat on 1.7 and one of the WARs on 1.6, so this is how you would ensure that you are using a specific version of Java to test your WAR code.
Upvotes: 2