1
votes

I'm using web services deployed on Axis2. I used to run my web services with Axis2 1.5.6 and it worked fine. Now I'm trying to run them with a more recent version : 1.6.3 but when I do so, I get this exception :

Caused by: java.lang.RuntimeException: java.lang.ClassNotFoundException: com.sun.ws.rs.ext.RuntimeDelegateImpl
    at javax.ws.rs.ext.RuntimeDelegate.findDelegate(RuntimeDelegate.java:122)
    at javax.ws.rs.ext.RuntimeDelegate.getInstance(RuntimeDelegate.java:91)
    at javax.ws.rs.core.MediaType.<clinit>(MediaType.java:44)
    ... 65 more
Caused by: java.lang.ClassNotFoundException: com.sun.ws.rs.ext.RuntimeDelegateImpl
    at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1305)
    at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1157)
    at java.lang.Class.forName0(Native Method)
    at java.lang.Class.forName(Class.java:264)
    at javax.ws.rs.ext.FactoryFinder.newInstance(FactoryFinder.java:62)
    at javax.ws.rs.ext.FactoryFinder.find(FactoryFinder.java:155)
    at javax.ws.rs.ext.RuntimeDelegate.findDelegate(RuntimeDelegate.java:105)
    ... 67 more

I guess the jersey-core.jar library isn't found and I don't know why because as I said everything works fine with the 1.5.6 version and I use the same .aar archive to deploy my web services on these both Axis2 versions. Moreover I put this dependency in my pom.xml :

<dependency>
        <groupId>com.sun.jersey</groupId>
        <artifactId>jersey-client</artifactId>
        <version>1.12</version>
</dependency> 

Any ideas ? Thanks

1

1 Answers

0
votes

Finally I made it working with adding jersey-bundle-1.19.jar into the lib directory of Axis2 (in webapps) and restart the tomcat.