0

I'm getting an error

Element <Batch> of parameter updates is missing or invalid

when trying to delete a file in sharepoint repository. My request is:

<?xml version="1.0" encoding="UTF-8"?>
<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/">
<SOAP-ENV:Header/>
<SOAP-ENV:Body>
    <ns0:UpdateListItems xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns0="http://schemas.microsoft.com/sharepoint/soap/">
        <ns0:listName>1e473281-959d-4a7f-952f-08aaccc3470e</ns0:listName>
        <ns0:updates>
            <ns0:Batch OnError="Continue">
                <ns0:Method ID="1" Cmd="Delete">
                    <ns0:Field Name="ID">1</ns0:Field>
                    <ns0:Field Name="FileRef">repisitoryurl/sites/Repo2/Repository/filename.docx</ns0:Field>
                </ns0:Method>
            </ns0:Batch>
        </ns0:updates>
    </ns0:UpdateListItems>
</SOAP-ENV:Body>
</SOAP-ENV:Envelope>

I'm performing this call through java code in Tibco BusinessWorks process. The response I'm getting is

The Http Server replied with a 5XX status code

from IIS so the actual error comes from IIS logs. The interesting part is that this exact call works well when performed through soapUI. The above request is also from the IIS logs just to be sure how it looks when it gets there. Of course I'm calling a proper service which is repositoryurl/sites/Repo2/_vti_bin/Lists.asmx.

Would anyone have an idea on what I'm doing wrong?

4

2 回答 2

0

您是否尝试通过 tcp gateway 之类的工具路由您的请求。它可能有助于弄清楚来自 TIBCO BW 和 SOAPUI 的请求之间有什么区别,因为肯定有区别;)

于 2014-05-19T21:41:32.147 回答
0

您提到您正在使用 Java 代码来执行 SOAP 请求,而不是使用 BW 的任何内置功能。请与我们分享您的 Java 代码。Java 代码是否可以独立(在 BW 之外)正常工作?通常我会建议使用 BW SOAP 或服务活动来发出 SOAP 请求。您可以通过在 URL 中附加“?wsdl”来获取所需的 WSDL:

http://repositoryurl/sites/Repo2/_vti_bin/Lists.asmx?wsdl

于 2014-05-22T08:32:06.750 回答