0

启动 MuleServer 时出现以下错误 -

11:07:44.523 [main] 错误 org.mule.MuleServer -


消息:在定义中搜索时未找到组件“{http://xyz.com/services/mvi}ProxyService”。检查端点中的命名空间属性是否丢失或具有无效值。可能的服务匹配:“[]”。定义的所有服务:[{http://xyz.com/services/mvi}MVIService] 类型:org.mule.api.lifecycle.InitialisationException 代码:MULE_ERROR-71999 JavaDoc: http: //www.mulesoft.org/ docs/site/current3/apidocs/org/mule/api/lifecycle/InitialisationException.html 对象:org.mule.module.cxf.config.FlowConfiguringMessageProcessor@4c372a96

我不确定为什么 Mule 正在寻找 ProxyService 而我已将 MVIServiceProxy 定义为组件类。我的 cxf 代理客户端配置是——

<flow name="mviProxyService">
    <http:inbound-endpoint address="http://localhost:61005/mvi/service" exchange-pattern="request-response">
        <cxf:proxy-service wsdlLocation="classpath:mvi.wsdl" namespace="http://xyz.com/services/mvi" />
    </http:inbound-endpoint>

    <component>
        <prototype-object class="com.xyz.services.mvi.MVIServiceProxy">
            <property key="requestDispatchUrl" value="jms://mviq.121.order?connector=jmsConnector" />
            <property key="responsePollUrl" value="jms://mviq.async.service.reply?connector=jmsConnector" />
            <property key="serviceTimeout" value="90000" />
        </prototype-object>
    </component>
    <request-reply timeout="60000">
        <jms:outbound-endpoint queue="mviq.121.order" />
        <jms:inbound-endpoint queue="mviq.async.service.reply" exchange-pattern="one-way" />
    </request-reply>
</flow>

=========== 修改流程 ================

<flow name="mviProxyService">
    <http:inbound-endpoint address="http://localhost:61005/mvi/service" exchange-pattern="request-response">
        <cxf:proxy-service wsdlLocation="classpath:mvi.wsdl" namespace="http://xyz.com/services/mvi" />
    </http:inbound-endpoint>

    <component class="com.xyz.services.mvi.MVIServiceProxy" />
    <request-reply timeout="60000">
        <jms:outbound-endpoint queue="mviq.121.order" />
        <jms:inbound-endpoint queue="mviq.async.service.reply" exchange-pattern="one-way" />
    </request-reply>
</flow>
4

1 回答 1

1

您需要servicecxf:proxy-service. 这是您在 WSDL元素的name属性中找到的值。wsdl:service

您的组件也不需要实现org.mule.api.lifecycle.Callable. 只要有一个接受javax.xml.stream.XMLStreamReader参数的公共方法,您就可以访问 XML 有效负载。

于 2012-07-24T19:52:15.413 回答