I'm using JDK 1.5 in my web project and using maven for compile.
I was facing this:
WebServiceException ("javax.xml.ws.WebServiceException: Provider com.sun.xml.ws.spi.ProviderImpl not found")
in my project. To fix that I used two approaches:
But after this I am facing this:
java.lang.NoClassDefFoundError:javax/xml/bind/JAXBContext
Does anyone have any idea that could help me?
Adding a dependency on jaxb-impl should be sufficient, as this transitively depends on jaxb-api, which is the JAR containing the class it's complaining about. In Java 6, javax.xml.bind
is part of the JRE by default so it would work out of the box there.
add this dependency to pom
<dependency>
<groupId>javax.xml</groupId>
<artifactId>jaxb-impl</artifactId>
<version>2.1</version>
</dependency>
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With