cxf-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Willem Jiang (JIRA)" <j...@apache.org>
Subject [jira] Commented: (CXF-3184) SOAPBindingUtil.getProxy can't load right class in OSGi
Date Fri, 18 Mar 2011 03:40:29 GMT

    [ https://issues.apache.org/jira/browse/CXF-3184?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13008310#comment-13008310
] 

Willem Jiang commented on CXF-3184:
-----------------------------------

This issue is not a critical issue, as I said in the JIRA, there are two ways to workaround
it.

BTW, Apache CXF doesn't maintain CXF 2.2.x branch any more, if you still want to use CXF 2.2.x,
you may consider to the commercial product supports from FuseSource.

> SOAPBindingUtil.getProxy can't load right class in OSGi
> -------------------------------------------------------
>
>                 Key: CXF-3184
>                 URL: https://issues.apache.org/jira/browse/CXF-3184
>             Project: CXF
>          Issue Type: Bug
>    Affects Versions: 2.2.12, 2.3.1
>            Reporter: Willem Jiang
>            Assignee: Willem Jiang
>             Fix For: 2.3.2, 2.2.13, 2.4
>
>
> As a fix for CXF-3143 SOAPBindingUtil.getProxy uses now thread context classloader.
> This causes the following problem:
> {code}
> Caused by: java.lang.IllegalArgumentException: interface org.apache.cxf.tools.common.extensions.soap.SoapBinding
is not visible from class loader
> 	at java.lang.reflect.Proxy.getProxyClass(Proxy.java:353)
> 	at java.lang.reflect.Proxy.newProxyInstance(Proxy.java:581)
> 	at org.apache.cxf.tools.util.SOAPBindingUtil.getProxy(SOAPBindingUtil.java:87)
> 	at org.apache.cxf.tools.util.SOAPBindingUtil.getSoapBinding(SOAPBindingUtil.java:274)
> 	at org.apache.cxf.tools.util.SOAPBindingUtil.createSoapBinding(SOAPBindingUtil.java:426)
> 	at org.apache.cxf.binding.soap.SoapBindingFactory.createSoapBinding(SoapBindingFactory.java:190)
> 	at org.apache.cxf.binding.soap.SoapBindingFactory.createBindingInfo(SoapBindingFactory.java:175)
> 	at org.apache.cxf.binding.AbstractBindingFactory.createBindingInfo(AbstractBindingFactory.java:80)
> 	at org.apache.cxf.frontend.AbstractWSDLBasedEndpointFactory.createBindingInfo(AbstractWSDLBasedEndpointFactory.java:360)
> 	at org.apache.cxf.jaxws.JaxWsServerFactoryBean.createBindingInfo(JaxWsServerFactoryBean.java:160)
> 	at org.apache.cxf.frontend.AbstractWSDLBasedEndpointFactory.createEndpointInfo(AbstractWSDLBasedEndpointFactory.java:257)
> 	at org.apache.cxf.frontend.AbstractWSDLBasedEndpointFactory.createEndpoint(AbstractWSDLBasedEndpointFactory.java:145)
> 	at org.apache.cxf.frontend.ServerFactoryBean.create(ServerFactoryBean.java:105)
> 	at org.apache.cxf.jaxws.JaxWsServerFactoryBean.create(JaxWsServerFactoryBean.java:177)
> 	at com.sabre.gateway.g2g.G2GInConnector.&lt;init&gt;(G2GInConnector.java:105)
> 	at com.sabre.gateway.g2g.G2GInConnector.&lt;init&gt;(G2GInConnector.java:76)
> 	at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
> 	at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
> 	at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
> 	at java.lang.reflect.Constructor.newInstance(Constructor.java:513)
> 	at org.springframework.beans.BeanUtils.instantiateClass(BeanUtils.java:126)
> {code}
> To avoid it we would to set context classloader to CXF bundle one before calling CXF
code that causes this exception or import the cxf packages in our bundle and set context classloader
to our bundle's one. 
> Both solutions look like workarounds.
> We need to make the SOAPBindingUtil.getProxy more smart to load  the class.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

Mime
View raw message