WCF <exceptionstring> System.Xml.XmlException:无法读取消息正文,因为它是空的。</exceptionstring>

时间:2015-09-03 11:06:12

标签: wcf c#-4.0

我编写WCF服务并将其托管在Windows服务(自托管)上,并公开method1method2。从这个方法1正常工作,但当我尝试消耗method2时,它给我一个错误,如

An error occurred while receiving the HTTP response to http://********/*******/service. This could be due to the service endpoint binding not using the HTTP protocol. This could also be due to an HTTP request context being aborted by the server (possibly due to the service shutting down). See server logs for more details.

当我在 XML 中检查app_tracelog时,有 System.Xml.XmlException: The body of the message cannot be read because it is empty

所以有人可以告诉为什么会这样吗?它适用于一种方法而不适用于其他方法。

0 个答案:

没有答案