title: unable to Load Class com.sun.xml.ws.api.SOAPVersion when deploying Application to Glassfish4
body: <p>Our Web-Application runs fine on Glassfish 3 and we want to migrate to Glassfish 4 and beyond.</p>
  <p>When i deploy the war file to Glassfish 4 i get the following Exception:</p>
  <pre><code>Caused by: java.lang.NoClassDefFoundError: Could not initialize class com.sun.xml.ws.api.SOAPVersion
  at com.sun.xml.ws.wsdl.parser.RuntimeWSDLParser.parseBinding(RuntimeWSDLParser.java:593)
  at com.sun.xml.ws.wsdl.parser.RuntimeWSDLParser.parseWSDL(RuntimeWSDLParser.java:475)
  at com.sun.xml.ws.wsdl.parser.RuntimeWSDLParser.parse(RuntimeWSDLParser.java:249)
  at com.sun.xml.ws.wsdl.parser.RuntimeWSDLParser.parse(RuntimeWSDLParser.java:209)
  at com.sun.xml.ws.wsdl.parser.RuntimeWSDLParser.parse(RuntimeWSDLParser.java:178)
  at com.sun.xml.ws.client.WSServiceDelegate.parseWSDL(WSServiceDelegate.java:364)
  at com.sun.xml.ws.client.WSServiceDelegate.&lt;init&gt;(WSServiceDelegate.java:322)
  at com.sun.xml.ws.client.WSServiceDelegate.&lt;init&gt;(WSServiceDelegate.java:231)
  at com.sun.xml.ws.client.WSServiceDelegate.&lt;init&gt;(WSServiceDelegate.java:212)
  at com.sun.xml.ws.client.WSServiceDelegate.&lt;init&gt;(WSServiceDelegate.java:208)
  at com.sun.xml.ws.spi.ProviderImpl.createServiceDelegate(ProviderImpl.java:119)
  at javax.xml.ws.Service.&lt;init&gt;(Service.java:92)
  </code></pre>
  <p>On Glassfish 3 there is no implementation of JaxWS and the default Implementation of the Java Runtime is used.</p>
  <pre><code>javax.xml.ws.Service
  com.sun.xml.internal.ws.client.WSServiceDelegate
  com.sun.xml.internal.ws.wsdl.parser.RuntimeWSDLParser
  </code></pre>
  <p>On Glassfish 4 there are two jarfiles who replace/overwrite this functionality.</p>
  <pre><code>webservices-api-osgi.jar and
  webservices-osgi.jar
  </code></pre>
  <p>webservices-api-osgi.jar contains the new Service class javax.xml.Service which then uses  the classes com.sun.xml.ws.* as shown in the exception.</p>
  <p>What i don't understand is why the class com.sun.xml.ws.api.SOAPVersion is not found it exist in webservices-osgi.jar just like com.sun.xml.ws.client.WSServiceDelegate and com.sun.xml.ws.wsdl.parser.RuntimeWSDLParser.</p>
  <p>Both Glassfish3 and Glassfish4 run on Oracle Java8 JDK.</p>