I get the following exception when trying to invoke the login() method
defined in this wsdl.

https://webservices.sandbox.netsuite.com/wsdl/v2014_2_0/netsuite.wsdl

java.lang.IllegalArgumentException: Can't find the BindingOperationInfo
with operation name {urn:platform_2014_2.webservices.netsuite.com}login.
Please check the message headers of operationName and operationNamespace.
at
org.apache.camel.component.cxf.CxfProducer.getBindingOperationInfo(CxfProducer.java:363)[161:org.apache.camel.camel-cxf:2.13.2]

This is the section from my blueprint.xml and the operationName &
operationNamespace are set correctly. I was successful invoking this
webservice directly from Java, but can't figure it out through Camel.

<cxf:cxfEndpoint id="nsEndpoint" address="
https://webservices.sandbox.netsuite.com/services/NetSuitePort_2014_2";
   wsdlURL="
https://webservices.sandbox.netsuite.com/wsdl/v2014_2_0/netsuite.wsdl";
   serviceName="c:NetSuiteService"
   endpointName="c:NetSuitePort"
   serviceClass="com.netsuite.webservices.platform_2014_2.NetSuiteService"
xmlns:c="urn:platform_2014_2.webservices.netsuite.com"
   >
</cxf:cxfEndpoint>

<camelContext xmlns="http://camel.apache.org/schema/blueprint";>
  <route>
    <from uri="jetty:http://0.0.0.0:8080/api/v1/netsuite"/>
    <setHeader headerName="operationName">
        <constant>login</constant>
    </setHeader>
    <setHeader headerName="operationNamespace">
        <constant>urn:platform_2014_2.webservices.netsuite.com</constant>
    </setHeader>
    <setBody><simple>${ref:loginRequest}</simple></setBody>
    <log message="${body}"/>
    <to uri="cxf:bean:nsEndpoint"/>
    <log message="${body}"/>
  </route>

Any idea as to what I'm doing wrong?

Reply via email to