Search code examples
web-serviceswsdlmule

Exposing WebService on Mule


I wanted expose an WebService on mule and its working.

  • My concern is that am not sure if this is the right approach to follow in exposing a webservice.
  • As I wanted to be able to view my Mule HTTP Inbound endpoint wsdl i.e

XXX:8084/HelloService?wsdl

, notice the actual service is running on port 8085.

 <flow name="WS_In" doc:name="WS_In">
    <http:inbound-endpoint address="http://localhost:8084/HelloService" exchange-pattern="request-response" doc:name="HTTP">
        <cxf:proxy-service wsdlLocation="http://localhost:8085/HelloService?WSDL" payload="envelope" namespace="http://example.org/HelloService"  service="Hello"/>
    </http:inbound-endpoint>        

    <http:outbound-endpoint exchange-pattern="request-response" host="localhost" port="8085" doc:name="HTTP" path="test"/>

</flow>

Solution

  • So you're not exposing a service but just proxying it right?

    Why not using the ready made pattern for that? See: http://www.mulesoft.org/documentation/display/current/Web+Service+Proxy+Pattern