3 Replies Latest reply on Sep 5, 2008 10:01 AM by Stefan Lecho

    How to change the SOAP Endpoint when using SOAPClient ?

    Stefan Lecho Newbie

      Hi,

      I'm using a SOAPClient-based Action to connect to an external Webservice. The WSDL offered by this service contains a SOAP Endpoint that is not correct, i.e. it should be overwritten with the correct one. By default, SOAPClient apparently uses the SOAP Endpoint defined in the WSDL.

      Is there a way to overwrite (property name="endpoint") this SOAP Endpoint in the definition of the Action ?

      WSDL Extract:

      <service name="PersonQuery">
       <port name="PersonQuerySoap" binding="s0:PersonQuerySoap">
       <soap:address location="http://vilcanota:7002/fphp/3.1/ws/PersonQuery.jws"/>
       </port>
      </service>


      Action definition:
      <action name="FSB-PersonQuery-findPerson" class="com.notary.esb.jboss.CredocSOAPClient">
       <property name="wsdl" value="https://e-depottest.smals-mvm.be/fphp/3.1/ws/PersonQuery.jws?WSDL=">
       <http-client-property name="file" value="/META-INF/https-fsb.properties" />
       </property>
       <property name="SOAPAction" value="https://e-depottest.smals-mvm.be/fphp/3.1/ws/findPerson"/>
      </action>


      Error Message:
      org.jboss.soa.esb.actions.ActionProcessingException: Failed to invoke SOAP Endpoint: 'http://vilcanota:7002/fphp/3.1/ws/PersonQuery.jws ' - 'https://e-depottest.smals-mvm.be/fphp/3.1/ws/findPerson'.
       at org.jboss.soa.esb.actions.soap.SOAPClient.invokeEndpoint(SOAPClient.java:443)
       at org.jboss.soa.esb.actions.soap.SOAPClient.process(SOAPClient.java:395)