0

We are compiling all our jars with target="5" so that the class files remain compatible with the older servers still running JDK5. Unfortunately, the web service compiled by jwsc takes the default java version, in this case 6.

    <jwsc   srcdir="${src.dir}" destdir="${dist.dir}" classpathref="project.class.path" debug="true">
        <jws file="org/foo/MainWebServiceImpl.java"
            compiledWsdl="../FooClient/gen-compiled-wsdl/${wsdl.foo.filebasename}_wsdl.jar" />
    </jwsc>

I don't have a "target" attribute in jwsc nor jws and the sub-elements don't seem to help. How can I get this task to compile Java 5 compatible classes ?

I am currently letting the jenkins server compile the code but I hate having to commit untested code to be able to deploy and test it.

Eric Darchis
  • 24,537
  • 4
  • 28
  • 49
  • 1
    You may check this out http://docs.oracle.com/cd/E13222_01/wls/docs92/webserv/anttasks.html#wp1039894. You could probably use compiler attribute. – jay c. Jul 24 '12 at 16:25
  • I tried to add compiler="javac1.5" to jwsc but it is still making java 6 classes (major version: 50). Nice try though, it looked promising. – Eric Darchis Jul 24 '12 at 20:49

0 Answers0