I have a a GWT application and I want to create a war file using hudson .So I have created a job and in the configuration I have checked the build option i.e invoke ant. so it uses the build.xml from my application and creates the war file . And my ant file i.e build.xml contains following targets:
1.Java compilation
2.GWT compilation
3.Create a war
4.Deploy it into tomcat with JDK 1.7.0
Application is compiling using jdk 1.6 and deploy it into the tomcat with jdk 1.7 but its not working. Is tomcat with JDK 1.7.0 is compatible with 1.6. ?? or is there another problem because some gwt-dev,gwt-user jars are still in war folder. In my tomcat logs following info is there:
INFO: Deploying web application archive /usr/local/tomcat_lh/webapps/Nightly.war
Dec 19, 2012 10:13:41 AM org.apache.catalina.loader.WebappClassLoader validateJarFile
INFO: validateJarFile(/usr/local/tomcat_lh/webapps/Nightly/WEB-INF/lib/gwt-dev.jar) - jar not loaded. See Servlet Spec 2.3, section 9.7.2. Offending class: javax/servlet/Servlet.class
Dec 19, 2012 10:13:41 AM org.apache.catalina.loader.WebappClassLoader validateJarFile
INFO: validateJarFile(/usr/local/tomcat_lh/webapps/Nightly/WEB-INF/lib/gwt-user.jar) - jar not loaded. See Servlet Spec 2.3, section 9.7.2. Offending class: javax/servlet/Servlet.class
Dec 19, 2012 10:13:41 AM org.apache.catalina.loader.WebappClassLoader validateJarFile INFO: validateJarFile(/usr/local/tomcat_lh/webapps/Nightly/WEB-INF/lib/javax.servlet.jar) - jar not loaded. See Servlet Spec 2.3, section 9.7.2. Offending class: javax/servlet/Servlet.class Dec 19, 2012 10:13:41 AM org.apache.catalina.core.StandardContext startInternal SEVERE: Error listenerStart
It is far, far more likely that you are doing something wrong.
I suspect if you deploy to Java 6 you will see the same issues, if not exactly the same errors. The only difference might be you would see different line numbers in the stack traces.
FYI: The code base for Java 7 and recent versions of Java 6 is very similar and even shares many of the same bugs. e.g. the was a well known bug in Java 7 when it was released to do with loop optimisation and people suggested waiting for it to be fixed before migrating. The interesting thing was the bug was also in Java 6, the only difference was that the optimisation was on by default in Java 7 and off by default in Java 6.
BTW: Most of the performance improvements in Java 7 were back ported into Java 6 so the only good reason to use Java 7 is a) you want to use the new syntax b) you are concerned that Java 6 is EOL.
In your case, there might be no good reason to use Java 7, for now.