Web services soap到rest转换期间来自wso2 esb的意外行为

Web services soap到rest转换期间来自wso2 esb的意外行为,web-services,rest,soap,wso2,wso2esb,Web Services,Rest,Soap,Wso2,Wso2esb,我已经用WSO2 ESB构建了一个代理服务,我想用它将REST Web服务(来自某个随机供应商)作为SOAP Web服务公开给另一个随机供应商。我遇到的问题是其中一个soap方法根本不起作用。所讨论的方法是“myvendorbpminsereclient”。我发现真正令人困惑的是,方法“MyVendorBPMatualizationCliente”几乎是一样的,但它确实有效!我收到错误代码405(http响应代码),因为属性中介“REST\u URL\u POSTFIX”似乎没有将路径的其余部分

我已经用WSO2 ESB构建了一个代理服务,我想用它将REST Web服务(来自某个随机供应商)作为SOAP Web服务公开给另一个随机供应商。我遇到的问题是其中一个soap方法根本不起作用。所讨论的方法是“myvendorbpminsereclient”。我发现真正令人困惑的是,方法“MyVendorBPMatualizationCliente”几乎是一样的,但它确实有效!我收到错误代码405(http响应代码),因为属性中介“REST\u URL\u POSTFIX”似乎没有将路径的其余部分附加到uri

顺序如下:

<proxy xmlns="http://ws.apache.org/ns/synapse" name="cadastroMyVendor" transports="https,http" statistics="enable" trace="enable" startOnLoad="true">
<target>
    <inSequence>
        <property name="request_action" expression="get-property('Action')"/>
        <switch source="get-property('request_action')">
            <case regex="myVendorBpmConsultaPeriodo">
                <property name="chave" value="myKey" scope="default" type="STRING"/>
                <property name="datainicio" expression="//datainicio" scope="default" type="STRING"/>
                <property name="datafim" expression="//datafim" scope="default" type="STRING"/>
                <property name="queryparams" expression="fn:concat('consulta/periodo?chave=',get-property('chave'))" scope="default" type="STRING"/>
                <property name="queryparams" expression="fn:concat(get-property('queryparams'),'&datainicio=')" scope="default" type="STRING"/>
                <property name="queryparams" expression="fn:concat(get-property('queryparams'),get-property('datainicio'))" scope="default" type="STRING"/>
                <property name="queryparams" expression="fn:concat(get-property('queryparams'),'&datafim=')" scope="default" type="STRING"/>
                <property name="queryparams" expression="fn:concat(get-property('queryparams'),get-property('datafim'))" scope="default" type="STRING"/>
                <property name="REST_URL_POSTFIX" expression="get-property('queryparams')" scope="axis2" type="STRING"/>
                <property name="HTTP_METHOD" value="GET" scope="axis2" type="STRING"/>
                <log level="full"/>
            <case regex="myVendorBpmInsereCliente">
                <property name="chave" value="myKey" scope="default" type="STRING"/>
                <property name="queryparams" expression="fn:concat('cliente/novo?chave=',get-property('chave'))" scope="default" type="STRING"/>
                <property name="REST_URL_POSTFIX" expression="get-property('queryparams')" scope="axis2" type="STRING"/>
                <property name="HTTP_METHOD" value="POST" scope="axis2" type="STRING"/>
                <xslt key="conf:/repository/scripts/dropTheSoap.xsl"/>
            </case>
            <case regex="myVendorBpmAtualizaCliente">
                <property name="chave" value="myKey" scope="default" type="STRING"/>
                <property name="queryparams" expression="fn:concat('cliente/atualiza?chave=',get-property('chave'))" scope="default" type="STRING"/>
                <property name="REST_URL_POSTFIX" expression="get-property('queryparams')" scope="axis2" type="STRING"/>
                <property name="HTTP_METHOD" value="PUT" scope="axis2" type="STRING"/>
                <xslt key="conf:/repository/scripts/dropTheSoap.xsl"/>
            </case>
            <default>
                <!-- code omitted -->
            </default>
        </switch>
        <send>
           <endpoint key="gov:/trunk/endpoints/myKey"/>
              <address uri="http://somehost:8080/STL-WS/myVendor/" format="pox"/>
           <endpoint key="gov:/trunk/endpoints/myKey"/>
        </send>
    </inSequence>
    <outSequence>
        <send/>
    </outSequence>
</target>
<description></description>

这是我从wso2 esb跟踪中得到的:

16:26:51090[-][HttpClientWorker-10]信息跟踪\u记录器结束:发送中介
16:26:51090[-][HttpClientWorker-10]信息跟踪记录器结束:序列
16:26:51324[-][HttpServerWorker-15]信息跟踪记录器代理服务Cadstro\u myVendor收到来自以下地址的新消息:127.0.0.1
16:26:51324[-][HttpServerWorker-15]信息跟踪记录程序消息发送至:/services/cadastro\u myVendor
16:26:51324[-][HttpServerWorker-15]信息跟踪记录器SOAPAction:MyVendorBPMinesReclient
16:26:51324[-][HttpServerWorker-15]信息跟踪记录器WSA操作:MyVendorBPMinesReclient
16:26:51324[-][HttpServerWorker-15]信息跟踪记录器使用代理服务的匿名顺序进行调解
16:26:51324[-][HttpServerWorker-15]信息跟踪\记录器启动:顺序
16:26:51324[-][HttpServerWorker-15]信息跟踪记录器序列::mediate()
16:26:51324[-][HttpServerWorker-15]信息跟踪\记录器开始:属性中介
16:26:51324[-][HttpServerWorker-15]信息跟踪\记录器设置属性:请求\作用域中的操作:默认为:myVendorBpmInsereCliente(即表达式的结果:get属性('action'))
16:26:51324[-][HttpServerWorker-15]信息跟踪记录程序结束:属性中介
16:26:51324[-][HttpServerWorker-15]信息跟踪\记录器启动:开关中介
16:26:51324[-][HttpServerWorker-15]信息跟踪\记录器XPath:get属性(“请求\操作”)计算结果为:myVendorBpmInsereCliente
16:26:51324[-][HttpServerWorker-15]信息跟踪记录程序找到匹配的案例:MyVendorBPMinesReclient
16:26:51324[-][HttpServerWorker-15]信息跟踪记录器序列::mediate()
16:26:51324[-][HttpServerWorker-15]信息跟踪\记录器开始:属性中介
16:26:51324[-][HttpServerWorker-15]信息跟踪记录器设置属性:范围处的chave:默认值为:myKey(即常量:myKey)
16:26:51324[-][HttpServerWorker-15]信息跟踪记录程序结束:属性中介
16:26:51324[-][HttpServerWorker-15]信息跟踪\记录器开始:属性中介
16:26:51324[-][HttpServerWorker-15]信息跟踪\记录器设置属性:作用域处的queryparams:默认为:cliente/novo?chave=myKey(即表达式的结果:fn:concat('cliente/novo?chave=',get属性('chave'))
16:26:51324[-][HttpServerWorker-15]信息跟踪记录程序结束:属性中介
16:26:51324[-][HttpServerWorker-15]信息跟踪\记录器开始:属性中介
16:26:51324[-][HttpServerWorker-15]信息跟踪\u记录器设置属性:REST\u URL\u作用域的后缀:axis2 to:cliente/novo?chave=myKey(即表达式的结果:get属性('queryparams'))
16:26:51324[-][HttpServerWorker-15]信息跟踪记录程序结束:属性中介
16:26:51324[-][HttpServerWorker-15]信息跟踪记录器开始:XSLT中介
16:26:51324[-][HttpServerWorker-15]警告跟踪\在样式表分析期间遇到记录器警告:javax.xml.transform.TransformerConfiguration异常:从属性节点开始的属性轴将永远不会选择任何内容
16:26:51324[-][HttpServerWorker-15]警告跟踪\在样式表分析期间遇到记录器警告:javax.xml.transform.TransformerConfiguration异常:从属性节点开始的子轴将永远不会选择任何内容
16:26:51324[-][HttpServerWorker-15]信息跟踪记录器输出方法:xml;编码:ISO-8859-1
16:26:51324[-][HttpServerWorker-15]信息跟踪记录器使用org.apache.synapse.util.jaxp.StreamSourceBuilder
16:26:51324[-][HttpServerWorker-15]信息跟踪记录器使用org.apache.synapse.util.jaxp.StreamResultBuilder
16:26:51324[-][HttpServerWorker-15]信息跟踪记录器转换已完成-处理结果
16:26:51324[-][HttpServerWorker-15]信息跟踪\记录器用结果替换节点
16:26:51324[-][HttpServerWorker-15]信息跟踪记录器结束:XSLT中介
16:26:51324[-][HttpServerWorker-15]信息跟踪\记录器开始:属性中介
16:26:51324[-][HttpServerWorker-15]信息跟踪\记录器设置属性:作用域:axis2到:POST的HTTP\方法(即常量:POST)
16:26:51324[-][HttpServerWorker-15]信息跟踪记录程序结束:属性中介
16:26:51324[-][HttpServerWorker-15]信息跟踪\记录器启动:发送中介
16:26:51324[-][HttpServerWorker-15]信息跟踪\记录器通过端点发送消息:gov//trunk/endpoints/myVendor解析到地址=http://somehost:8080/STL-WS/myVendor/
16:26:51324[-][HttpServerWorker-15]信息跟踪记录器SOAPAction:MyVendorBPMinesReclient
16:26:51324[-][HttpServerWorker-15]信息跟踪记录器WSA操作:MyVendorBPMinesReclient
16:26:51340[-][HttpServerWorker-15]信息跟踪记录程序结束:发送中介
16:26:51,340 [-]