JaxWsDynamicClientFactory IllegalArgumentException Can not set final com.sun.tools.internal.xjc.reader.internalizer.InternalizationLogic

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

JaxWsDynamicClientFactory IllegalArgumentException Can not set final com.sun.tools.internal.xjc.reader.internalizer.InternalizationLogic

dave.chen
Hi,

I am using JaxWsDynamicClientFactory to createWS client factory as follwing:

        JaxWsDynamicClientFactory wsClientFactory = JaxWsDynamicClientFactory.newInstance();
        Client wsClient = wsClientFactory.createClient(wsAddress);

It runs fine outside of karaf, but when running in side karaf (2.3.1), it throws the following error:


java.lang.IllegalArgumentException: Can not set final com.sun.tools.internal.xjc.reader.internalizer.InternalizationLogic field com.sun.tools.internal.xjc.reader.internalizer.DOMForest.logic to org.apache.cxf.endpoint.dynamic.DynamicClientFactory$1
        at sun.reflect.UnsafeFieldAccessorImpl.throwSetIllegalArgumentException(UnsafeFieldAccessorImpl.java:164)
        at sun.reflect.UnsafeFieldAccessorImpl.throwSetIllegalArgumentException(UnsafeFieldAccessorImpl.java:168)
        at sun.reflect.UnsafeQualifiedObjectFieldAccessorImpl.set(UnsafeQualifiedObjectFieldAccessorImpl.java:83)
        at java.lang.reflect.Field.set(Field.java:680)
        at org.apache.cxf.endpoint.dynamic.DynamicClientFactory.hackInNewInternalizationLogic(DynamicClientFactory.java:817)
        at org.apache.cxf.endpoint.dynamic.DynamicClientFactory.createClient(DynamicClientFactory.java:314)
        at org.apache.cxf.endpoint.dynamic.DynamicClientFactory.createClient(DynamicClientFactory.java:235)
        at org.apache.cxf.endpoint.dynamic.DynamicClientFactory.createClient(DynamicClientFactory.java:228)
        at org.apache.cxf.endpoint.dynamic.DynamicClientFactory.createClient(DynamicClientFactory.java:183)

Does anyone know why?
Loading...