title: JDK 11: java.lang.NoClassDefFoundError: javax/xml/ws/handler/soap/SOAPHandler
body: <p>We are migrating to openjdk 11 from jdk 8. Some of our projects that uses soap to call third party apis are failing with error:</p>
  
  <pre><code>java.lang.NoClassDefFoundError: javax/xml/ws/handler/soap/SOAPHandler
  </code></pre>
  
  <p>After doing some research, I tried by adding dependencies :</p>
  
  <p>[
  <strong>references:</strong> </p>
  
  <ul>
  <li><p><a href="https://stackoverflow.com/questions/43574426/how-to-resolve-java-lang-noclassdeffounderror-javax-xml-bind-jaxbexception-in-j">How to resolve java.lang.NoClassDefFoundError: javax/xml/bind/JAXBException in Java 9</a></p></li>
  <li><p><a href="https://stackoverflow.com/questions/48204141/replacements-for-deprecated-jpms-modules-with-java-ee-apis">Replacements for deprecated JPMS modules with Java EE APIs</a></p></li>
  </ul>
  
  <p>]</p>
  
  <pre><code> &lt;dependency&gt;
          &lt;groupId&gt;javax.annotation&lt;/groupId&gt;
          &lt;artifactId&gt;javax.annotation-api&lt;/artifactId&gt;
      &lt;/dependency&gt;
      &lt;dependency&gt;
          &lt;groupId&gt;xml-apis&lt;/groupId&gt;
          &lt;artifactId&gt;xml-apis&lt;/artifactId&gt;
      &lt;/dependency&gt;
      &lt;dependency&gt;
          &lt;groupId&gt;javax.xml.bind&lt;/groupId&gt;
          &lt;artifactId&gt;jaxb-api&lt;/artifactId&gt;
          &lt;version&gt;2.3.1&lt;/version&gt;
      &lt;/dependency&gt;
      &lt;dependency&gt;
          &lt;groupId&gt;com.sun.xml.bind&lt;/groupId&gt;
          &lt;artifactId&gt;jaxb-core&lt;/artifactId&gt;
          &lt;version&gt;2.3.0.1&lt;/version&gt;
      &lt;/dependency&gt;
      &lt;dependency&gt;
          &lt;groupId&gt;com.sun.xml.bind&lt;/groupId&gt;
          &lt;artifactId&gt;jaxb-impl&lt;/artifactId&gt;
          &lt;version&gt;2.3.1&lt;/version&gt;
      &lt;/dependency&gt;
      &lt;dependency&gt;
          &lt;groupId&gt;javax.xml.soap&lt;/groupId&gt;
          &lt;artifactId&gt;javax.xml.soap-api&lt;/artifactId&gt;
          &lt;version&gt;1.3.5&lt;/version&gt;
      &lt;/dependency&gt;
  </code></pre>
  
  <p>Did not work. may I get an idea on the alternatives?</p>