【发布时间】:2019-02-06 12:49:14
【问题描述】:
我想用 WSE 3.0 调用一个 Java-Soap-Service,我使用 WSDL-File 生成了一个代理,但该服务需要 MTOM 来获取它的数据。 我也按照本教程进行了操作,效果很好,但没有帮助: http://twit88.com/blog/2008/05/14/net-mtom-enabled-your-application-using-wse/
我得到的例外是:
System.FormatException: "WSE839: An HTTP response was received that used the following content type: text/xml;charset=UTF-8. The following content type was expected: multipart/related; type=application/xop+xml."
我知道 WSE 3.0 已经过时,如果有其他方法请告知。
有人可以帮忙吗?
【问题讨论】:
-
WSE 很古老,一定要用吗?查看链接文章下的 cmets,让 MTOM 与 WSE 正常工作可能是不可能的。
-
不,我不需要。你能告诉我怎么做吗?
-
我建议您使用 wcf,请参阅 here 获取代码示例以帮助您入门。请注意,有时让肥皂消息在 java 和 .net 之间工作可能是一个真正的 PITA。