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

Daniel Kulp commented on CXF-4892:
----------------------------------

Are you sure you don't have some mix of versions of CXF libraries?   The call 
at 
AbstractWSDLBasedEndpointFactory.createBindingInfo(AbstractWSDLBasedEndpointFactory.java:345)
  in the latest code is:

{code}
serviceFactory.sendEvent(FactoryBeanListener.Event.BINDING_OPERATION_CREATED, 
inf, boi, m);
{code}

which would have the additional param.   
                
> java.lang.ArrayIndexOutOfBoundsException: 2 in 
> org.apache.cxf.ws.policy.PolicyAnnotationListener
> ------------------------------------------------------------------------------------------------
>
>                 Key: CXF-4892
>                 URL: https://issues.apache.org/jira/browse/CXF-4892
>             Project: CXF
>          Issue Type: Bug
>          Components: WS-* Components
>    Affects Versions: 2.7.4
>            Reporter: Jerome Revillard
>
> Hi,
> I just wanted to test some policies bind to an operation as there was an 
> update commit from CXF-4816 (commit 1443423).
> I obtain:
> Exception in thread "main" java.lang.ArrayIndexOutOfBoundsException: 2
>       at 
> org.apache.cxf.ws.policy.PolicyAnnotationListener.handleEvent(PolicyAnnotationListener.java:112)
>       at 
> org.apache.cxf.service.factory.AbstractServiceFactoryBean.sendEvent(AbstractServiceFactoryBean.java:72)
>       at 
> org.apache.cxf.frontend.AbstractWSDLBasedEndpointFactory.createBindingInfo(AbstractWSDLBasedEndpointFactory.java:345)
>       at 
> org.apache.cxf.frontend.AbstractWSDLBasedEndpointFactory.createEndpointInfo(AbstractWSDLBasedEndpointFactory.java:258)
>       at 
> org.apache.cxf.frontend.AbstractWSDLBasedEndpointFactory.createEndpoint(AbstractWSDLBasedEndpointFactory.java:143)
>       at 
> org.apache.cxf.frontend.ClientFactoryBean.create(ClientFactoryBean.java:90)
>       at 
> org.apache.cxf.frontend.ClientProxyFactoryBean.create(ClientProxyFactoryBean.java:155)
>       at 
> org.apache.cxf.jaxws.JaxWsProxyFactoryBean.create(JaxWsProxyFactoryBean.java:156)
> The problematic source code is:
>       case BINDING_OPERATION_CREATED:
>             BindingOperationInfo boi = (BindingOperationInfo) args[1];
>             Method m = (Method)args[2];
>             addPolicies(factory, boi.getOperationInfo(), m);
>             break;
> In my case, args length is only 2: 
> [[BindingInfo 
> http://schemas.xmlsoap.org/soap/],[BindingOperationInfo:{http://pandora.maatg.fr/ns/sal}echoStringNotSecured]]
> Best,
> Jerome

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Reply via email to