对于使用AXIS1(例如AXIS 1.4)作为端点的一些遗留Web服务,是否有任何WSO2 ESB与AXIS1 WSDL通信的教程或示例,以及使用REST或AXIS2作为客户端的服务代理? 我目前正在使用WSO2 ESB 4.8.1,但找不到任何帮助解决此问题的参考。谢谢!
答案 0 :(得分:0)
我能够在WSO ESB2 4.8.1中为指定的服务创建服务而没有问题,至少我没有得到任何关于WSDL格式的错误。
但是,你完全正确 - 有一些问题,那么你试图在基于Axis2的WSO2 ESB中使用基于Axis1的服务:
正如您所正确提到的,Axis1使用rpc / encoded样式,Axis2使用文档样式。为了使它一起工作,然后你发布服务的wsdl,你应该使用follow属性,以rpc格式在WSO2中发布服务:
<parameter name="useOriginalwsdl">true</parameter>
即使您尝试使用遵循以下定义的服务:
<?xml version="1.0" encoding="UTF-8"?>
<proxy xmlns="http://ws.apache.org/ns/synapse"
name="PrimaveraProxy"
transports="https,http"
statistics="disable"
trace="disable"
startOnLoad="true">
<target>
<outSequence>
<send/>
</outSequence>
<endpoint>
<wsdl service="MainService2Service"
port="mainservice"
uri="https://primavera-unifier.oracleindustry.com/ws/services/mainservice?wsdl"/>
</endpoint>
</target>
<publishWSDL uri="https://primavera-unifier.oracleindustry.com/ws/services/mainservice?wsdl"/>
<parameter name="useOriginalwsdl">true</parameter>
<description/>
</proxy>
你会得到错误(然后你会试着调用一些方法):
未找到操作的端点引用(EPR)是 /services/PrimaveraProxy.PrimaveraProxyHttpSoap12Endpoint和WSA Action = null。如果此EPR以前可以访问,请联系 服务器管理员。
这是因为原始WSDL具有空的soapAction参数,例如:
<wsdl:operation name="getRoleList">
<wsdlsoap:operation soapAction=""/>
要修复它,您应该在本地编辑原始WSDL,方法是为soapActions插入名称,然后将其放入服务定义(例如内联或通过注册表)。
希望这些建议能为您提供帮助