1

有没有人遇到这个问题?

我们有一个使用 weblogic 开发的 Web 服务,我能够在soapUI 中成功导入 wsdl 并生成一个能够成功调用 Web 服务的客户端。然后我还能够为axis2生成一个客户端jar并将其包含在一个项目中。但是当我尝试在 java 代码中调用 Web 服务时,我得到了:

Unable to find a matching Operation for this remote invocation <xml-fragment>

知道是什么导致了问题吗?

谢谢,
czetsuya

4

2 回答 2

1

同样的问题。

ListarRegionesDocument request = ListarRegionesDocument.Factory.newInstance();

<?xml version='1.0' encoding='UTF-8'?><soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
  <soapenv:Body>
    <xml-fragment/>
  </soapenv:Body>
</soapenv:Envelope>

解决方案

ListarRegionesDocument request = ListarRegionesDocument.Factory.newInstance();
//Add code
ListarRegiones lstRegion = ListarRegiones.Factory.newInstance();
request.setListarRegiones(lstRegion );

<?xml version='1.0' encoding='UTF-8'?>
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
    <soapenv:Body>
        <reg:listarRegiones xmlns:reg="http://region.webservices.col.direccionNormalizada.telefonica.cl/"/>
    </soapenv:Body>
</soapenv:Envelope>
于 2019-11-24T17:21:18.263 回答
0

我能够通过在soapUI 中使用Axis1 来解决这个问题。看来我们的客户正在使用一种旧技术。

于 2013-01-07T03:02:18.833 回答