我使用 cxf 代理服务在 mule 3.3.0 CE 中发布了一个 Web 服务。
<mule xmlns:http="http://www.mulesoft.org/schema/mule/http"
xmlns:spring="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns="http://www.mulesoft.org/schema/mule/core" xmlns:cxf="http://www.mulesoft.org/schema/mule/cxf"
xmlns:cxf-core="http://cxf.apache.org/core" xmlns:mule-xml="http://www.mulesoft.org/schema/mule/xml"
xmlns:vm="http://www.mulesoft.org/schema/mule/vm" xmlns:doc="http://www.mulesoft.org/schema/mule/documentation"
xmlns:mule-ss="http://www.mulesoft.org/schema/mule/spring-security"
xmlns:ss="http://www.springframework.org/schema/security" xmlns:test="http://www.mulesoft.org/schema/mule/test"
xsi:schemaLocation=" http://www.mulesoft.org/schema/mule/http http://www.mulesoft.org/schema/mule/http/current/mule-http.xsd
http://www.mulesoft.org/schema/mule/cxf http://www.mulesoft.org/schema/mule/cxf/current/mule-cxf.xsd
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-current.xsd
http://www.mulesoft.org/schema/mule/core http://www.mulesoft.org/schema/mule/core/current/mule.xsd
http://cxf.apache.org/core http://cxf.apache.org/schemas/core.xsd
http://www.mulesoft.org/schema/mule/xml http://www.mulesoft.org/schema/mule/xml/current/mule-xml.xsd
http://www.mulesoft.org/schema/mule/vm http://www.mulesoft.org/schema/mule/vm/current/mule-vm.xsd
http://www.mulesoft.org/schema/mule/spring-security http://www.mulesoft.org/schema/mule/spring-security/3.3/mule-spring-security.xsd
http://www.springframework.org/schema/security http://www.springframework.org/schema/security/spring-security-3.1.xsd
http://www.mulesoft.org/schema/mule/test http://www.mulesoft.org/schema/mule/test/current/mule-test.xsd "
version="CE-3.3.0">
<flow name="wbs" doc:name="wbs">
<http:inbound-endpoint host="localhost" port="9094"
path="myPath/app" exchange-pattern="request-response" doc:name="HTTP">
</http:inbound-endpoint>
<cxf:proxy-service doc:name="wbsrv" service="AppWSService"
wsdlLocation="schema/wsdl/App/WSService.wsdl" namespace="http://wbservice.com/"
payload="body"></cxf:proxy-service>
<copy-properties propertyName="SOAPAction" doc:name="Property" />
<cxf:proxy-client doc:name="wbsrv" />
<http:outbound-endpoint address="http://websrv.mydns.com:8080/App/WSService"
doc:name="HTTP" encoding="UTF-8" responseTimeout="1000000"
exchange-pattern="request-response">
</http:outbound-endpoint>
</flow>
我的 mule 服务器的 IP 是:192.168.0.59。我可以通过该 Ip (192.168.0.59) 看到出站地址 ( http://websrv.mydns.com:8080/App/WSService )。在运行网络服务之后,我可以看到我使用 cxf 代理发布它的 wsdl,但是当我使用 SoapUI 检查它时,我无法收到响应。我在 SoapUI xml 中有以下错误:
<soap:Fault>
<faultcode>soap:Server</faultcode>
<faultstring>Failed to route event via endpoint: DefaultOutboundEndpoint{endpointUri=http://websrv.mydns.com:8080/App/WSService, connector=HttpConnector
{ name=httpConnector lifecycle=start this=16a2c7b
numberOfConcurrentTransactedReceivers=4
createMultipleTransactedReceivers=true connected=true
supportedProtocols=[http] serviceOverrides=
session.handler=org.mule.session.NullSessionHandler } , name='endpoint.http.websrv.mydns.com.8080.App.WSService',
mep=REQUEST_RESPONSE, properties={},
transactionConfig=Transaction{factory=null, action=INDIFFERENT,
timeout=0}, deleteUnacceptedMessages=false, initialState=started,
responseTimeout=1000000, endpointEncoding=UTF-8,
disableTransportTransformer=false}. Message payload is of type:
websrvMethod
</faultstring>
</soap:Fault>
如何重定向出站地址,我可以在每个服务器和 IP 中使用它?