在请求和响应之间使用不同的 SOAP 命名空间/版本是否合法? [英] Is it legal to have different SOAP namespaces/versions between the request and response?
问题描述
第三次我现在认为这个问题是由于 SOAP 版本不匹配(1.1 请求,1.2 响应)伪装成命名空间问题.混合版本是否违法,或者只是错误的风格?如果我不能更改我的 SOAP 版本或服务的版本,我是否完全不走运?
THIRD I now believe that this problem is due to a SOAP version mismatch (1.1 request, 1.2 response) masquerading as a namespace problem. Is it illegal to mix versions, or just bad style? Am I completely out of luck if I can't change my SOAP version or the service's?
第二次澄清错误信息,并试图减少tl;dr"-ness.
SECOND Clarified error message, and tried to reduce "tl;dr"-ness.
[链接已删除,不相关]
[Link deleted, not related]
使用soapUI,我发送的请求以:
Using soapUI, I'm sending a request that starts with:
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" ...
并获得以以下开头的回复:
and getting a response that starts with:
<soap:Envelope xmlns:soap="http://www.w3.org/2003/05/soap-envelope" ...
我知道服务正在获取信息,因为下线的进程正在运行.但是,我的soapUI 测试步骤失败了.它有两个活动断言:SOAP Response"和Not SOAP Fault".失败标记位于SOAP 响应"旁边,带有以下消息:
I know the service is getting the info, because processes down the line are working. However, my soapUI teststep fails. It has two active assertions: "SOAP Response" and "Not SOAP Fault." The failure marker is next to "SOAP Response," with the following message:
行 -1:元素信封@http://www.w3.org/2003/05/soap-envelope 不是有效的信封@http://schemas.xmlsoap.org/soap/envelope/ 文档或有效的替代.
line -1: Element Envelope@http://www.w3.org/2003/05/soap-envelope is not a valid Envelope@http://schemas.xmlsoap.org/soap/envelope/ document or a valid substitution.
我尝试混合和匹配命名空间前缀和架构 URL.更改前缀似乎没有效果;更改 URL 会导致 VersionMismatch
错误.我也尝试过使用替换组,但这似乎不合法.
I have tried mixing and matching the namespace prefixes and schema URLs. Changing prefixes seems to have no effect; changing URLs causes a VersionMismatch
error. I have also tried to use a substitution group, but that doesn't seem to be legal.
推荐答案
好的,编辑后的问题似乎有答案:这取决于."
Okay, the edited question does seem to have an answer: "It depends."
W3C:从 SOAP/1.1 到 SOAP 版本 1.2 的版本转换
这篇关于在请求和响应之间使用不同的 SOAP 命名空间/版本是否合法?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!