title: call third party web service using apache camel
body: <p>I am new to camel</p>
  
  <p>I am trying to call webservice using camel java dsl</p>
  
  <pre><code>from("cxf://http://darshan:8080/sampleWebService/SampleTestServicePort?wsdlURL=http://darshan:8080/sampleWebService/SampleTestServicePort?wsdl&amp;serviceName={http://ws.test.com/}SampleTestServiceService&amp;portName={http://ws.test.com/}SampleTestServicePort&amp;dataFormat=MESSAGE")
  </code></pre>
  
  <p>following is my wsdl file:</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="UTF-8"?&gt;
  &lt;definitions xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:tns="http://ws.test.com/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="http://schemas.xmlsoap.org/wsdl/" targetNamespace="http://ws.test.com/" name="SampleTestServiceService"&gt;
      &lt;types&gt;
          &lt;xsd:schema&gt;
              &lt;xsd:import namespace="http://ws.test.com/" schemaLocation="http://darshan:808O/sampleWebService/SampleTestServicePort?xsd=1"&gt;&lt;/xsd:import&gt;
      &lt;/xsd:schema&gt;
      &lt;/types&gt;
      &lt;message name="sayHello"&gt;
          &lt;part name="parameters" element="tns:sayHello"&gt;&lt;/part&gt;
      &lt;/message&gt;
      &lt;message name="sayHelloResponse"&gt;
          &lt;part name="parameters" element="tns:sayHelloResponse"&gt;&lt;/part&gt;
      &lt;/message&gt;
      &lt;portType name="SampleTestServiceDelegate"&gt;
          &lt;operation name="sayHello"&gt;
              &lt;input message="tns:sayHello"&gt;&lt;/input&gt;
              &lt;output message="tns:sayHelloResponse"&gt;&lt;/output&gt;
          &lt;/operation&gt;
      &lt;/portType&gt;
      &lt;binding name="SampleTestServicePortBinding" type="tns:SampleTestServiceDelegate"&gt;
          &lt;soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="document"&gt;&lt;/soap:binding&gt;
          &lt;operation name="sayHello"&gt;
              &lt;soap:operation soapAction=""&gt;&lt;/soap:operation&gt;
              &lt;input&gt;
                  &lt;soap:body use="literal"&gt;&lt;/soap:body&gt;
              &lt;/input&gt;
              &lt;output&gt;
                  &lt;soap:body use="literal"&gt;&lt;/soap:body&gt;
              &lt;/output&gt;
          &lt;/operation&gt;
      &lt;/binding&gt;
      &lt;service name="SampleTestServiceService"&gt;
          &lt;port name="SampleTestServicePort" binding="tns:SampleTestServicePortBinding"&gt;
              &lt;soap:address location="http://darshan:808O/sampleWebService/SampleTestServicePort"&gt;&lt;/soap:address&gt;
          &lt;/port&gt;
      &lt;/service&gt;
  &lt;/definitions&gt;
  </code></pre>
  
  <p>That gives no error but also output is nothing. </p>
  
  <p>Please suggest me what is wrong in my code.</p>
  
  <p>Thanks in advance</p>